Fixed has_next loop and has_prev loop in posts.html