[wp-trac] [WordPress Trac] #16802: is_page() doesn't accept a full path
WordPress Trac
wp-trac at lists.automattic.com
Wed Mar 9 12:52:14 UTC 2011
#16802: is_page() doesn't accept a full path
-------------------------+-----------------------------
Reporter: johnbillion | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Query | Version: 3.1
Severity: minor | Keywords:
-------------------------+-----------------------------
If you have a page at example.com/foo/bar, then `is_page('foo/bar')` will
return false on that page.
The `is_page()` function only checks the ID, title and post name, not the
full path.
If the $page parameter passed to `is_page()` contains a slash then we
should check the full path. If I get a chance I'll see if I can whip up a
patch in the next couple of days.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/16802>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list