Code Snippet: WordPress Page Template Redirect to child page

Sometimes you need a simple way to redirect a parent page directly to it’s first child page in WordPress. This little snippet is a WordPress page template to be used in your theme. It includes support for WPML, in case you still use my least favorite translation plugin in the universe. I strongly suggest you use something like Polylang or Multilingual Press to create multilingual WordPress sites, but that’s material for another post.

Page Template

Check out the gist for this page template.

Leave a Comment