[wp-hackers] Template Hierarchy In A Plugin

Braydon ronin at braydon.com
Sun Aug 7 19:33:36 UTC 2011


We really need to have full manual mode for URL and templates and take 
WordPress to the Grand Prix.

On 08/05/2011 03:25 PM, Alex Andrews wrote:
>   Dear all,
>
> What is the best way to take advantage of the way in which WordPress automatically guesses, and correctly loads the right template for a custom post type, but within a plugin rather than a theme?
>
> So in a plugin I load a series of custom post types, and tell WordPress where the template files for them are, which it then loads in an automated manner. So album-single.php loads as we would expect if it were under the template directory and so on?
>
> I attempted to Google this, but obviously quite difficult to get through the thickets of results to it out!
>
> Thanks for the help,
>
> Alex
>



More information about the wp-hackers mailing list