I’m currently working on a site using WP as a cms and I’ve hit a roadblock. I’m using main parent pages to show product (child) pages as thumbnails. This works ok, the problem is I’ve got a special offers page that may not have child pages. I want to test if the page has children, if it does show the thumbnails as it is currently, if not display a generic “sorry we don’t have anything on offer” message.
Anyone know if I can test if it the page has child pages or not (sorry, PHP isn’t my strong point!)
Thanks in advance
- The topic ‘If/Else Statement for if a page has child pages?’ is closed to new replies.