[wp-trac] Re: [WordPress Trac] #6801: Should have a template file
for front page
WordPress Trac
wp-trac at lists.automattic.com
Sun Jun 14 15:44:04 GMT 2009
#6801: Should have a template file for front page
---------------------------+------------------------------------------------
Reporter: AaronCampbell | Owner: anonymous
Type: enhancement | Status: reopened
Priority: normal | Milestone: 2.9
Component: Template | Version:
Severity: normal | Resolution:
Keywords: needs-patch |
---------------------------+------------------------------------------------
Comment(by Denis-de-Bernardy):
how about using:
{{{
if ( is_front_page() && !is_home() && $template =
get_front_page_template() ) {
} else if ( is_home() && $template = get_home_template() ) {
}
}}}
and then, in get_home_template(), we add a check: if is_front_page() and
try front-page.php.
the case to avoid is, if it's a static front page, we want to behave like
a page, but if it's a blog front page, we'd also want to catch front-
page.php.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/6801#comment:27>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list