Considering how regularly new versions of Firefox now come along, that's quite some bug fix list in version 10! http://t.co/K3I2vLpW 1 week ago


3rd
Nov 10

Finding the length of WordPress Posts



I’m just finished converting my plugin pages to use my new WP README Parser plugin. However, I had a nagging feeling that I might have missed, at the very least, 1. But how can I easily tell without going through them all one-by-one?

Well, their length is a give-away as instead of pages of text, there’s now a single call to my plugin. A quick bit of SQL will show the length of each post and/or page in characters, allowing me to see if any of the original versions still exist.

Here is an example using standard table naming and will list the details of pages…

SELECT ID, post_title, guid, length(post_content) AS 'Post Length'
  FROM `wp_posts`
 WHERE post_type = 'page'
   AND post_status <> 'draft'
   AND post_status <> 'trash'
 ORDER BY length(post_content)

That 3rd line can be modified to WHERE post_type = 'post' for posts, or combined with the original to list both posts and pages.

Otherwise, it simply lists the ID, title and URL for each page as well as the character length of the page content. It excludes drafts and anything in the trash. The final list is sequenced by the length of the page.

Not sure if this is useful to anyone, but just in case….!

Delicious Digg Facebook LinkedIn Read It Later reddit StumbleUpon Twitter SeparatorEmail Google Translate PDF Online Print Friendly



20th
Oct 10

WP README Parser WordPress Plugin Released


I mentioned last week that I was working on a plugin that will parse and display a WordPress plugin README file in a post or on a page. Well, after a lot of sweat and tears, it’s finished and released!

WP README Parser has taken a lot of work and I hope people – particularly WordPress plugin developers who wish to display README content on their site – find it useful.

I’ll be upgrading this site to immediately make use of it.

Delicious Digg Facebook LinkedIn Read It Later reddit StumbleUpon Twitter SeparatorEmail Google Translate PDF Online Print Friendly



15th
Oct 10

Simple Timed Content – WordPress Plugin Updated


Simple Timed Content is a plugin that provides a shortcode, for use in posts and pages, that will show or hide content depending on the current date and/or time.

Earlier this week I was contacted by Jeff Kereakoglow who suggested that I add an “On Day” and “Off Day” option to Simple Timed Content, allowing content to be turned on or off depending on the day of the week. He also highlighted the fact that the time I was using was dependant on the host server and not the visitors local time.

So, one massive re-write later, and all of that has been added, plus more. Massive re-write because, to add the day function, meant the triggering logic needed a re-think.

I’ve also added a PHP function call option so that the plugin can be used from other parts of theme, for instance the sidebar, as well as in posts and pages.

Thanks for Jeff for his suggestions.

Delicious Digg Facebook LinkedIn Read It Later reddit StumbleUpon Twitter SeparatorEmail Google Translate PDF Online Print Friendly