[theme-reviewers] Child themes discussion

michael at mfields.org michael at mfields.org
Sat Jan 22 18:29:44 UTC 2011


> <img src="<?php echo get_stylesheet_directory_uri(); ?>/images/header.jpg"
> alt="header image" />
>
> If a child theme exists, it will use the one from the chlid theme
> directory,
> if child theme does not exist will grab from the parent theme

But this means that if a child theme exists, it must include
/images/header.jpg. I made the function to allow for

<img src="<?php echo artpress_file_locate( '/images/header.jpg' ); ?>"
> alt="header image" />

The file will always exist in the parent, but if a child theme adds
header.jpg to its images folder, this will be used instead. This way it's
optional to include the file in the child.



More information about the theme-reviewers mailing list