WordPress Database Charset/Collate

There are $wpdb->charset and $wpdb->collate. I am not sure if or when one of these values might be empty, so it is better to prepare for empty values … From my DB class: /** * Get table charset and collation. * * @since 2012.10.22 * @return string */ protected static function get_wp_charset_collate() { global $wpdb; … Read more

XML RPC post produces immediate revision with odd post_date_gmt

Alright. I think I cracked it. <dateTime.iso8601>20140111T20:39:15</dateTime.iso8601> Should be: <dateTime.iso8601>20140111T20:39:15Z</dateTime.iso8601> Looks like the toolkit I was using didn’t quite implement iso8601 perfectly (or wordpress isn’t – not sure). I’m using Node WordPress and tracked down that it uses the module Node XML RPC to actually send the XML RPC. This seems to be where the … Read more

optimise SQL wordpress call

The query itself may need to be optimized (SQL is not my speciality, though). However, don’t forget you can store the results of an expensive operation in cached memory. WordPress offers a Transients API to make things easy. Here’s a quick example: // Try to load the value from cache $transient_key = ‘my_query’; $value = … Read more

WP Posts Not Adding Up

Definitely time for an upgrade. 🙂 Try logging into your admin and following the link below. Just make sure to change ‘yoururl.com’ to whatever your website name is. If you have posts in the trash, that should take you to your trash to see them. http://yoururl.com/wp-admin/edit.php?post_status=trash&post_type=post