A function like is_page() but returns true if on any sub page of given page
In my header I use this code:
if(is_page("stores")) {
// Do something
}
I run some code if on the page stores
but what I want to do is run that code if the page is stores
or any page that is a sub page of stores. Not only that, but is recursive so if we are on a sub sub sub page of stores
the code still runs.
Topic recursive pages conditional-content Wordpress
Category Web