[wp-trac] Re: [WordPress Trac] #6848: is_front_page() and is_home() erroneously returns true on /blog/page/2 and so forth

WordPress Trac wp-trac at lists.automattic.com
Sun Apr 27 00:10:35 GMT 2008


#6848: is_front_page() and is_home() erroneously returns true on /blog/page/2 and
so forth
-----------------------------------------------+----------------------------
 Reporter:  Pinoy.ca                           |        Owner:  anonymous
     Type:  defect                             |       Status:  new      
 Priority:  normal                             |    Milestone:  2.5.2    
Component:  Template                           |      Version:  2.5      
 Severity:  normal                             |   Resolution:           
 Keywords:  is_front_page is_home 2nd-opinion  |  
-----------------------------------------------+----------------------------
Comment (by Viper007Bond):

 Replying to [comment:7 Pinoy.ca]:
 > Replying to [comment:6 Viper007Bond]:
 > > it'd be really hard to find front page, but page 2.
 >
 > I'm sorry I don't understand you.

 If `is_front_page()` returned false on `/page/2/`, that would make it
 harder to do stuff (like display a message or whatever) on those pages
 while avoiding doing it on like page 2 of the latest posts (you could do
 hackery to display like only a certain category on your homepage for
 example).

 However, if it continues to return true, it's easy to exclude paged
 results via `!is_paged()`.

 Basically, it's a lot more flexible how it is now. It's easier to exclude
 pages (now) than it is is determine if it's the front of the site, but
 paged (proposed).

 Get it? Sorry, it's hard to explain, heh.

-- 
Ticket URL: <http://trac.wordpress.org/ticket/6848#comment:8>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list