[wp-hackers] IMHO

BB bb at bbiverson.com
Thu Aug 5 14:50:32 UTC 2004


A few days ago, I asked for help with a code snippet that would allow me to
have a global post-to-post chronological navigation for my WP setup.  (My
weblog is set to 1 posts paged.)  I got some great help between here and the
WP support forums.  The viable solution ended up being (I have it just under
the content div):

 

<?php

previous_post('%','Previous', 'no', 'no', 1, '');

 

if (!((basename (__FILE__) == 'index.php') && ($_SERVER['QUERY_STRING'] ==

''))) {

?>

 

&nbsp; <a href="<?php bloginfo('url'); ?>">Latest</a> &nbsp; 

 

<?php

next_post('%','Next', 'no', 'no', 1, ''); 

 

}

?>

 

I feel that this would be a good addition to the default index.php file.
The calendar is great, but using it to go from post to post, can get a bit
tedious.

 

Also, for a better reading experience, wouldn't it make sense to read the
monthly archives from the first day of the month, the oldest post, rather
than the last day of the month, the latest post (which is how it is now)?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: /pipermail/hackers_wordpress.org/attachments/20040805/9433ab1b/attachment.htm


More information about the hackers mailing list