Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
QUESTION if_parent; if_child
#1
I am wondering if there is a way to determine if a given page is a child page, a parent page, or both.

My ultimate goal is that if a page is a parent page, I would like to display a list of their child pages, if a page is a child page, I would like to display a link back to the parent, and if it is both, then it would display both links.
Reply
#2
if(getChildren or getChildrenMulti etc
in caching_functions

for is child check
$pagesArray[$pageId]['parent'] is not empty()
or
returnPageField($page,'parent') not empty
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#3
Thanks! I'll try that and see how it goes.
Reply




Users browsing this thread: 1 Guest(s)