[wp-hackers] by passing the entire template hierarchy

John Blackbourn johnbillion+wp at gmail.com
Mon Jul 7 13:39:29 UTC 2014


It's a strange thing to need to do (you might want to re-think what
exactly it is you're doing) but it's simple enough:

add_filter( 'template_include', function( $template ) {
    return locate_template( 'index.php' );
} );

On 7 July 2014 10:34, Haluk Karamete <halukkaramete at gmail.com> wrote:
> Is there a way to by pass the great system known as the  WordPress Template
> Hierarchy so that WordPress shoots the ball straight to the last resort
> which is index.php?
> _______________________________________________
> 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