[wp-trac] [WordPress Trac] #21423: wp_list_pages() is not aware of the current page inside the loop so the correct css classes are not set
WordPress Trac
wp-trac at lists.automattic.com
Mon Jul 30 14:36:33 UTC 2012
#21423: wp_list_pages() is not aware of the current page inside the loop so the
correct css classes are not set
--------------------------+-----------------------------
Reporter: thedaysse | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 3.4.1
Severity: minor | Keywords:
--------------------------+-----------------------------
Because is_page() doesn't work inside the loop any widget that calls
wp_list_pages() also fails to put the right css on the generated list. The
fix is for wp_list_pages() to have an extra option so we can tell it
explicitly what $ID we are on when we call it:
'current_page' => 0, // would do it
Fixing is_page() and is_singular() so that they give the expected results
inside the loop would also solve the issue
--
Ticket URL: <http://core.trac.wordpress.org/ticket/21423>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list