What is a Theme framework? And why use it?
Basically, a Theme framework is a WordPress theme that you can extend using functions, styles and child themes.
Child themes are most of the times two files: function.php and style.css. An optional directory containing images can be used as well. Child themes can’t work without a parent theme, which is a synonym for “Theme framework”.
So, why use a Theme framework instead of a “classic” theme? The answer is quite simple: When you need to modify one of WordPress’ functionalities, you don’t edit the core file. Instead, you use a plugin of a hook to modify what you need without editing the core files. That way, you can customize WordPress to fit your needs while at the same time being able to upgrade it without loosing your mods.
Theme frameworks use the same logic: Modify as you need, but don’t edit core file so you’ll be able to upgrade.
In this tutorial, I’m using the Thematic theme framework, a GPL licenced theme brought to you by Ian Stewart. Thematic is in my opinion very powerful and optimized. Therefore, you may be interested in taking a look at other WordPress frameworks as well, such as Hybrid, Headway, Thesis or WP Framework.
Creating the child theme
Right now, you should know what a Theme Framework is and why you should use them. But enough theory for now, let’s get ready to create our own child theme for Thematic.
Download Thematic
Of course, the first thing to do is to download the Thematic Theme Framework. Once finished, unzip the file on your hard drive.
If you want, you can activate Thematic and take a look at your blog. Thematic can be used as a parent theme, or in standalone mode. Without a child theme, Thematic is ready to use and features a really gorgeous typography. There’s no images or even colors, so that you can create your child theme and make Thematic fit your needs, either in its look or functionality.

Create your child theme directory
After you unzipped the Thematic zip file, open the directory. You’ll find a sub directory called thematicsamplechildtheme. Copy it and paste it on the wp-content/themes directory. Rename it with your desired theme name. In this tutorial, I’ll use the name catmatic.
Modify the stylesheet info
Navigate to your new catmatic (or whatever you named it) directory. you’ll find two files: The first is functions.php and the other one is style.css. Open style.css in your favorite text editor. You’ll find the following lines:
/* Theme Name: A Thematic Child Theme Theme URI: Description: Use this theme to start your Thematic Child Theme development. Author: Ian Stewart Author URI: http://themeshaper.com/ Template: thematic Version: 1.0 Tags: Thematic . Thematic is © Ian Stewart http://themeshaper.com/ . */
What you have to do is simply to name your child theme and give more info about it, as in the following example :
/* Theme Name: Catmatic Theme URI: http://www.catswhocode.com Description: A Thematic child theme. Author: Jean-Baptiste Jung Author URI: http://www.catswhocode.com Template: thematic Version: 1.0 Tags: Thematic . Thematic is © Ian Stewart http://themeshaper.com/ . */
Once finished, save the style.css file.
Styling the theme
At this point of the tutorial, we have prepared our child theme but we haven’t started to code yet. So what are we waiting for? The first stage of child theme development is to give the desired look to the Thematic framework, using CSS and images.
Add CSS Styles
Defining CSS styles on your theme child is definitely easy. All you have to do is to add styles to the style.css file from the catmatic directory.
Add images
Adding images to your child theme isn’t hard either. To do so, navigate to wp-content/themes/catmatic and create a new directory named images. (You can name it the way you want, but images is pretty much self-explanatory)
Then, simply put image files in the images directory. If you want to link to those images using CSS, you’ll do the following:
body{
background: #fff url(images/bg.gif) repeat-x top left;
}Supercharging Thematic
Well, after having some CSS fun, your Thematic child theme should look as you want it to. Though, what if you want to modify the theme? Should you edit Thematic theme files?
No, you shouldn’t. Of course, it is possible to do it but it is not a good practice at all. If you’re familiar with WordPress development, you probably know about hooks, which allow you to “hook” a custom function to another. In addition to WordPress hooks, Thematic also adds lots of hooks that allow you to do many things to customize your child theme.
Add functions/hooks
Add your custom functions to your child theme is easier than it seems: Open the functions.php file from your child theme directory and paste your functions there.
To help you get started, here is a bunch of ready-to-use functions:
Modify theme link:
function my_footer($thm_footertext) {
$thm_footertext = 'Powered by WordPress, theThematic Theme framework and the Catmatic child theme.';
return $thm_footertext;
}
add_filter('thematic_footertext', 'my_footer');Define where to use excerpt/full posts
$full_content = false;
function childtheme_content($content) {
if ($full_content) {
$content= 'full';
} elseif (is_home() || is_front_page()) {
$content= 'excerpt';
} elseif (is_single()) {
$content = 'full';
} elseif (is_tag()) {
$content = 'excerpt';
} elseif (is_search()) {
$content = 'excerpt';
} elseif (is_category()) {
$content = 'excerpt';
} elseif (is_author()) {
$content = 'excerpt';
} elseif (is_archive()) {
$content = 'excerpt';
}
return $content;
}
add_filter('thematic_content', 'childtheme_content');Display Thematic menu above header
function remove_thematic_actions() {
remove_action('thematic_header','thematic_access',9);
}
add_action('wp','remove_thematic_actions');
add_action('thematic_aboveheader','thematic_access');Add a favicon
function childtheme_favicon() { ?>
<link rel="shortcut icon" href="<?php echo bloginfo('stylesheet_directory') ?>/images/favicon.png"/>
<?php }
add_action('wp_head', 'childtheme_favicon');
Activate your theme
Right now, you should have a child theme that fit your needs in both the look and functionality. The last thing we have to do is to upload the theme to your wp-content/themes directory and activate it. Make sure that Thematic is available on your wp-content/themes directory as well.





My name is Jean-Baptiste Jung and I'm the man behind Cats Who Code. I started to use the Internet back in 1998 and started to create websites three years laters in 2001.
21 Comments
I love WordPress and have needed a great tutorial for creating Child Themes for my staff! Thanks Cats!!!
Great article. I’ve never used a theme framework before, but this makes me want to give it a try.
Very good . good article
I never used thematic either but I think I will try it after this for my next project.
Thank you for the great article, and including the custom functions.
If you don’t mind me sharing it here, another useful function (provided below) gets and displays the content from a page. Here, a welcome blurb is being added to the header in position 6 via the thematic_header hook.
/** Welcome blurb added to header div **/
function welcome_blurb() {
if (is_front_page()) { // show blurb on front page
$n = 16; // page id
$welcome_blurb = get_page($n);
print $welcome_blurb->post_content;
} else { // else show this blurb on all other pages
$n = 440; // page id
$welcome_blurb = get_page($n);
print $welcome_blurb->post_content;
}
}
add_action(’thematic_header’,'welcome_blurb’, 6);
thanks!
this is a great tutorial
I started using thematic but I had not time to go deep into it, because thematic is a framework where you have to take time to learn it.
That’s why I clicked on this tutorial to “learn it faster” but I am a bit sad that it is more for beginners level.
Nevertheless good article.
NICE! well put together post.
@oustcat : Nice function, thanks for sharing it
I was trying to find the “catmatic directory” that was mentioned, but I dont actually know what it is or how to find it. Can you point me in the right direction?
@Carla : “Catmatic” is a custom name for the child theme created in this tutorial. Unless you created it, you won’t find it
Is this the sort of thing used on large corporate wordpress magazine type blogs with one featured post on the index page followed by a list of sub posts all formatted differently to the main one, and with secondary featured posts in a number of categories followed by a list of other posts in that category?
I really want to get into wordpress development a little more and your post has opened my eyes to the possibilities.
It is even easier than I have thought. Thanks!
I’ve just had a company ask me to help them modify their website that was created with Thematic. (Problem is the developer modified the Thematic theme files instead of creating a child theme – but never mind).
So, when you activate the theme, I guess you activate the child theme not the Thematic theme? And, is there somewhere you go to get a list of functions/hooks to add to your child theme’s functions.php?
Sorry, just trying to get my head around this and this is the first blog post I’ve come across. No need to answer the questions
Frame work helps to give style and good designs to your template and theme. It is a awesome post and will be surely of great help to web designers and coders. Even newbie will gain a boost to their knowledge and people will surely like it.
What do you think is the best wp theme framework ? headway or thesis ?
@Lucian : I prefer Headway which is more powerful than Thesis. If you’re looking to buy Headway, you can get a 20% discount here.
Thanks for the headsup on “thematics”. I am looking at Headway and it does look very impressive, it will be nice to have a powerful basic framework without having to get stuck into programming and coding. Is headway easy to use or will I need to do a course to get to grips with it?
@Peter Coursely : Headway is great because you can do lots of things with little or no coding. If you’re interested in Headway, you’ll get a 20% discount there.
I never used thematic either but I think I will try it after this for my next project.
This came at a good time because I was researching Child Themes a few weeks ago. I was up in the air over using Thematic or Hybrid. I ended up not going with either because I wasn’t looking forward to paying anything and the free documentation was poor. Also, I would imagine the learning curves for using the frameworks are steep.
Tip: It is possible to use any theme as a parent theme.
3 Trackbacks
[...] WordPress: How to easily create a Thematic child theme [...]
[...] Cats Who Code: How to easily create a Thematic child them. (it’s time for me to get butt in gear and start the blog redesign seriously…) [...]
[...] WordPress: How to easily create a Thematic child theme [...]