[buddypress-trac] [BuddyPress] #2982: single.php has wrong function and format to show next and/or previous post link.

buddypress-trac at lists.automattic.com buddypress-trac at lists.automattic.com
Thu Dec 30 08:08:03 UTC 2010


#2982: single.php has wrong function and format to show next and/or previous post
link.
-------------------------+-----------------------------
 Reporter:  chestnut_jp  |      Owner:
     Type:  defect       |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  Theme        |    Version:  1.3
 Keywords:               |
-------------------------+-----------------------------
 /bp-themes/bp-default/single.php has a wrong function and format to show
 the next and/or previous post link.

 [ Original ]
 <div class="alignleft"><?php next_posts_link( __( '&larr; Previous
 Entries', 'buddypress' ) ) ?></div>
 <div class="alignright"><?php previous_posts_link( __( 'Next Entries
 &rarr;', 'buddypress' ) ) ?></div>

 Should be

 [ Changed to ]

 <div class="alignleft"><?php next_post_link('%link', __( '&larr; Previous
 Entries', 'buddypress' ) ) ?></div>
 <div class="alignright"><?php previous_post_link('%link', __( 'Next
 Entries &rarr;', 'buddypress' ) ) ?></div>

 However, this still will collapse the format of page, thus I recommend:

 [ Changed to ]

 <table>
 <tr><td class="alignleft">
 <?php previous_post_link('%link', '&larr;&nbsp;%title') ?>
 </td><td class="alignright">
 <?php next_post_link('%link', '%title&nbsp;&rarr;') ?>
 </td></tr>
 </table>

 Note that %title can be changed to the default of "__( '&larr; Previous
 Entries', 'buddypress' )" and "__( 'Next Entries &rarr;', 'buddypress' )"

-- 
Ticket URL: <http://trac.buddypress.org/ticket/2982>
BuddyPress <http://buddypress.org/>
BuddyPress


More information about the buddypress-trac mailing list