I saw a couple threads in here asking about creating links to the next & previous posts within single.php, but no answers. I worked up something that works for me and looks good, so figured I’d share.
The code starts after the ‘div id=container’ line & ends before the ‘arcticle id=post’ line
<?php previous_post('« « %', '', 'yes'); ?> | <?php next_post('% » »', '', 'yes'); ?>
just copy/paste the entire thing into single.php…lines 2-3 of the code in this post is actually just one really long line. It’ll paste correctly.
info about the php command: http://codex.wordpress.org/Next_and_Previous_LinkscatanaParticipant
Man, it works great for me too.
I have a question it’s possible to set the font size? what should I do, any hint will be appreciated.AkikoParticipant
Hi many thanks for this, helped me a lot!
For the font size, I managed to increase it by adding this:
before and after.
I also altered the text alignment, so mine looks like this:
<div style=”text-align:left”><font size=4>
<?php previous_post(‘« « %’, ”, ‘yes’); ?> | <?php next_post(‘% » »’, ”, ‘yes’); ?></font>
Hope this helps!
You must be logged in to reply to this topic.