Created
June 13, 2014 22:00
-
-
Save kaseybon/e226bbe4e2130c657fce to your computer and use it in GitHub Desktop.
Add to WordPress index.php to redirect the blog page to the first blog post.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require('./wp-blog-header.php'); | |
if (have_posts()) : the_post(); | |
header("location: ".get_permalink()); | |
exit; | |
endif; | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment