Tag Info

Hot answers tagged

4

That's a Serialized Array which turns an array into a simple string so that it can be inserted into a database ( since you cannot just insert arrays into a database as they are ). For more information you can read into the PHP docs for serialize() There is also some WordPress functions which do the same: maybe_serialize() and maybe_unserialize(). This ...


2

Since this is a plugin, it's probably going to get axed, but generally speaking in WordPress if you want to get a posts featured image and you have access to the post ID (which I'm assuming you do), you can always do this: $thumb_url = wp_get_attachment_url( get_post_thumbnail_id( $post->ID ) ); So without looking at the plugin, it looks like you might ...


2

Plugins load before themes. The earliest hooks available to plugins is plugins_loaded (or muplugins_loaded for mu-plugins), while themes run on after_setup_theme and later hooks. So you better just load the file [that contains the class] on a specific hook in your plugin. It probably is best to load it on a lower priority than the default 10. Below I use 5 ...


2

In the meta_query arguments, try changing your 'type' => 'CHAR', to 'type' => 'DATETIME', You can opt for any one of these, depending your needs: type (string) - Custom field type. Possible values are 'NUMERIC', 'BINARY', 'CHAR', 'DATE', 'DATETIME', 'DECIMAL', 'SIGNED', 'TIME', 'UNSIGNED'. Default value is 'CHAR'. But ...


1

I found the problem. I didn't realize this was a generic message for pretty much all errors. I stripped everything out of the activation routine (similar to above) and ran it... got no errors. Started adding "stuff" back. And it appears a call to flush() at the end of the activation function trying to force the /wp-content/debug.log to be flushed to disk was ...



Only top voted, non community-wiki answers of a minimum length are eligible