[wp-hackers] bloginfo('template_directory'); returns parent theme's directory, is this intended?

William P. Davis will.davis at gmail.com
Mon Jan 10 18:20:23 UTC 2011


Yes, this is intentional. Bloginfo('stylesheet_directory') returns the child theme's directory. 

Will
Sent from my BlackBerry® wireless device

-----Original Message-----
From: Ryan Bilesky <rbilesky at gmail.com>
Sender: wp-hackers-bounces at lists.automattic.com
Date: Mon, 10 Jan 2011 10:17:39 
To: <wp-hackers at lists.automattic.com>
Reply-To: wp-hackers at lists.automattic.com
Subject: [wp-hackers] bloginfo('template_directory');
 returns parent theme's directory, is this intended?

I am wanting to make several tweaks to a theme for my use, and I've chose to
do so by making a child theme to be upgrade safe.  However I noticed that I
changed some colors around on my child themes css but I was not seeing the
change.  So I viewed source of my site and saw that it was using the parent
theme's css file.  In the header.php this was the code:

<link rel="stylesheet" type="text/css" href="<?php
bloginfo('template_directory'); ?>/style.css" />
I fixed this by adding a modified version of header.php in my child themes
directory that has the css url hard coded.  So my question is this, is
bloginfo('template_directory'); supposed to return the parent theme or child
theme directory when called?
_______________________________________________
wp-hackers mailing list
wp-hackers at lists.automattic.com
http://lists.automattic.com/mailman/listinfo/wp-hackers


More information about the wp-hackers mailing list