Blog » WordPress Customization Blog

Proper tag for home page conditionals

If you’re trying to use a conditional to display or not display something on your home page, you should be aware that this conditional:
is_home()
only works for the blog posts page.  If you have your home set to a static page, it won’t affect that page.  It will continue to work for whatever page you have [...]

Changing placement of a meta box on admin pages

I recently added a plugin, and the meta box on post and page screens appeared before the excerpt meta box.  The client was going to have multiple contributors and we didn’t want them to see this plug-in first (it had a very large meta box) and potentially forget that there was an excerpt box and [...]

Growing up with child themes

The topic of my talk at WordCamp Fraser Valley 2009 was Growing Up With Child Themes.  Briefly, a child theme is one that uses the style sheet and template files of another theme – the parent – and can override them.  The basic idea is that instead of modifying the parent files, you simply drop [...]

Listing a parent page and its children

I wanted to have a set of pages – a parent and sub-pages or child pages – that I could use as a separate menu down on the footer (for privacy, disclaimers, etc.).  The issue was, how to code WordPress to display them as a single list of pages.
First I tried this:
<ul>
<?php wp_list_pages(’title_li=&include=416&depth=2′); ?>
</ul>
thinking that [...]

Proper syntax for including a sub-page in a series of included pages

Suppose you already have a specified set of pages you’re displaying in a menu.  You’ve used the include parameter in your tag, so it looks like this:
<?php wp_list_pages(’title_li=&depth=1&include=69,181,95,73′); ?>
You want to add a sub-page to this list of included pages, but when you do that, it doesn’t show.  You might think it’s because you have [...]

Using Shortcode outside of the_content()

I had some shortcode that couldn’t be used in the body of certain posts. It needed to be inserted in a template, but of course that prevented it from being rendered by WordPress.

All trademarks and copyrights appearing on this website are the property of their respective owners. All rights Reserved.