Displaying Text based on Parent Page’s Name/Slug
-
Hi all, just looking to find out how to specify a bit of text to be displayed if the parent page’s name equals a certain value. Currently I have a tree like this:
Attorneys
Houston
Attorney 1
Attorney 2Austin
Attorney 3
Attorney 4What I’m looking to do is when the attorney page (which has it’s own template) is called, it checks to see what the parent page’s name is (in this cause Houston or Austin) and displays a block of text that I define in the template.
I’ve been working a bit with conditionals, so I’m pretty squared away on that, but I just can’t seem to figure out how to reference the page name correctly.
Viewing 8 replies - 1 through 8 (of 8 total)
Viewing 8 replies - 1 through 8 (of 8 total)
- The topic ‘Displaying Text based on Parent Page’s Name/Slug’ is closed to new replies.