Displaying More ‘Recent Posts’ Links
I desired once again to increase the number of ‘Recent Posts’ links in my blogs’ sidebars. The default in WordPress 2.8.4 is 15 links but I wanted 100 to appear. These changes got erased that I had made in 2.7.1 when I upgraded to WordPress 2.8. So, I’ve updated these instructions to account for the changes of location of the relevent code in 2.8. You can see the original instructions for 2.7.1 by clicking here. I’ve included the revised instructions for 2.8.4 below:
File to change: $WP_ROOT/wp-inclues/default-wigits.php. Note that this is a different file than when I did this before for WordPress 2.7.1.
Find the Wp_Widget_Recent_Posts() routine in the file given above. In WordPress 2.8.4 this function should start at line 513 if you’ve not changed the file from what’s contained in the official 2.8.4 release code.
Modify the following code snippet at lines 542 and 543 from…
else if ( $number > 15 )
$number = 15;
to
else if ( $number > 100 )
$number = 100;
Don’t forget to upload your modified file and to change the count of links to display in the admin pages of the “Recent Posts” widget for your WordPress site.
I’ve verified that these changes work for WordPress 2.8.4 and 2.8.5.
Enjoy.
Tom