Does any one know if there is some sort of functionality for checking if a page is a subpage or not. Also if a page is a subpage of a particular page.
I.E. is_child("portfolio");
If not I am going to write this functionality.
Does any one know if there is some sort of functionality for checking if a page is a subpage or not. Also if a page is a subpage of a particular page.
I.E. is_child("portfolio");
If not I am going to write this functionality.
I have made a small plugin recently that works for me re this functionality that I hope you can use.
It's available here:
Thanks, this worked great.
Works for me, too. Thanks!
WFM too but decendant is spelled as descendant :)
AWesome! This would be an awesome addition to the core imo, thank you so much, now I wont' have to pull the rest of my hair out.
Since I haven't found a plugin yet which has is_child-functionality even for categories, postings as well as for pages, I gave up on searching and wrote one for myself.
Works with IDs, titles and slugs as search-term.
As I explained here:
http://wordpress.org/support/topic/79687?replies=1
I'd like something which displays the current sibling pages and the parent page - but no other top level pages (even "folded").
This would be very useful for building dynamic menus in static web sites using WP as a backend.
I think we're trying to do the same thing. Create the feel of seperate blogs in one. I have some butchered code (I know null about PHP) running at the top of this page.
http://www.villageboating.com/vb/
Is that what you are thinking? I can post it if someone wants to clean it up.
I just thought I would bump this because I posted a topic elsewhere about an easy way to get subcategories to highlight its parent category's tab... this is perfect, it gets the category highlighted when it is a page in that category, a page in a subcategory of that category, or the archive of that subcategory.
Thanks a lot for this plugin!
(I used Gronkh's by the way, I am not sure how the other one is)
This topic has been closed to new replies.