For the 1st question, see previous_post and next_post template tags. <?php bloginfo('url'); >
returns the url for the Home link.
As for the 2nd question, see the examples for the_content tag.
(Sorry for providing just links but I’m an avid Codex fan and I feel that people should be directed towards it. Hope you can build up the rest. If not, ask for more 🙂 )
I second the Codex thing. Folks are working hard there and it can only benefit us if its supported. Plus it cuts down repetetive answers in the forum. Its our resource – lets celebrate it.
I have tried the previous_post and next_post tags, I seem to get a sql error no matter where I put them, can someone show me a real example and a posting location to get it to work? I also think I need to have it in a conditional so I can tell it to only show on the blog post, and not on the main page where multiple blog posts are listed.
well, if you have a Post template (single.php) you can put it there without any conditionals. But if you’re not using post template, you can put a <?php if ( is_single() ) { ?> <?php } ?>
somewhere
Here’s a cleaned code snippet off my single.php. The first line’s just to show some context, that is, the functions should be used inside the Loop:
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<?php previous_post('« %','Previous entry','no') ?>
<?php next_post('% »','Next entry','no') ?>