It sounds like you're trying to do something that doesn't belong as a
theme, but whatever. This should do the trick:
add some `!is_feed()` logic in there if you still want feeds to work.
Post by Haluk KarameteThank you guys for your input.. I appreciate it.
John, I've built a new infustructure where things work differently and in
this infrustructure, the whole theme is done by a single index.php. And
that's always the case - which nullifies the need for the concept known as
template-hiearachy.
So there will never-ever be a need to say category.php.
I do not wish to get into the details here as to why I]ve built a framework
as such , and why I should or should not have done so etc.
Please note that this is not about overwriting the template hierarchy.
It's about totally by passing it
- which I have a feeling is not possible.
In the case of hooking into the "template_include" (or "template_redirect"
for that matter), it's an overwrite.
As you know, those hooks are run after wordpress core deployed the
template-hierarchy and in some cases 7 or 8 files have already been probed
for their existence. - which is exactly the process I'm trying to prevent
from taking place.
and as to the get_header option, Mikael, it's the same situation. By the
time, get_header hook sees the world, all the file_exists operations have
already been performed.
Let me put it this way, we all know index.php is the last resort in the
template-hierarchy.
Is there a hook that I can turn index.php being the first-resort?
Post by John BlackbournIt's a strange thing to need to do (you might want to re-think what
add_filter( 'template_include', function( $template ) {
return locate_template( 'index.php' );
} );
Post by Haluk KarameteIs there a way to by pass the great system known as the WordPress
Template
Post by Haluk KarameteHierarchy so that WordPress shoots the ball straight to the last resort
which is index.php?
_______________________________________________
wp-hackers mailing list
http://lists.automattic.com/mailman/listinfo/wp-hackers
_______________________________________________
wp-hackers mailing list
http://lists.automattic.com/mailman/listinfo/wp-hackers
_______________________________________________
wp-hackers mailing list
http://lists.automattic.com/mailman/listinfo/wp-hackers