4

Redirect To Single Post Page

This article is about template redirecting in WordPress using template_redirect hook. This is a very simple but very handy for a WordPress blogger who wants to redirect the user to the single post template/full post view (even if there is only index.php) when there is only one post in the archive/category/tag. It’s helpful to a new blog site when there is a few articles like mine. I’ve found this handy and using it on my site, so I think someone else will like it too. Simply paste this code snippet in the functions.php and you are done.

Latest Blog