WordPress: is_child function

Every once in a while I would like to test whether the current page is a descendant of another page. This is particularly useful if you want to display certain content on a subset of your pages only. Although the Codex suggests a similar is_tree function I would like to present an extended version here.

I’ve packaged the functionality inside a WordPress plugin called is_child that you can download here. Unzip it, upload it to wp-content/plugins and activate the plugin.

Continue reading →

WordPress: Add notes to the comment form

Most themes use the comment_form action which can be used to add arbitrary things to the comment form with a plugin. This post presents a simple plugin that uses custom fields to add special notes to this section.

You can download the plugin here, unzip it, upload it to your wp-content/plugins directory and activate it.

Continue reading →

Generate quiz for Contact Form 7

If you’re using Contact Form 7 for WordPress you might want to protect your forms with a quiz: this is a field where the user has to enter the result of predefined questions. Since we don’t want to annoy the user with a complicated task we’d like to generate very easy to answer questions.

Continue reading →

Removing the WordPress Generator meta tag completely

WordPress adds a generator tag at various locations. Basically that’s a good idea because it provides a means to check out the different versions of WordPress that are actively being used in the blogosphere.

Continue reading →