Next topic,last topic in pagination for prosilver style

Guides & Snippets for phpBB3. Try the Snippets here and share Your own Snippets
There is no support here! Only Read Access!
Locked
User avatar
Steve
BBCoder VI
BBCoder VI
Posts: 847
Joined: 05 Mar 2010, 01:10
BBCodes: 2000
Favourite BBCode: p**n tube
Favourite MOD: Non of Stokers

Next topic,last topic in pagination for prosilver style

Post by Steve »

I found this out age,s ago and remember toringt posting it has own snippet irrc on the old board when he requested it in a support topic.
This is already in subsilver2 styles so why not add it to prosilver,we will add the links to the pagination, what it does is allow you to view the newer or older topic in the forum your are viewing.
recomend using this snippet also will take you to the last post of the topic : viewtopic.php?f=9&t=1086&p=6418#p6418

Instructions
Open styles/prosilver/template/viewtopic_body.html
find:

Code: Select all

	<!-- IF PAGINATION or TOTAL_POSTS -->
		<div class="pagination">
			<!-- IF U_VIEW_UNREAD_POST and not S_IS_BOT --><a href="{U_VIEW_UNREAD_POST}">{L_VIEW_UNREAD_POST}</a> &bull; <!-- ENDIF -->{TOTAL_POSTS}
			<!-- IF PAGE_NUMBER --><!-- IF PAGINATION --> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF --><!-- ENDIF -->
		</div>
	<!-- ENDIF -->
replace with:

Code: Select all

	<!-- IF PAGINATION or TOTAL_POSTS -->
		<div class="pagination">
			<a href="{U_VIEW_OLDER_TOPIC}">{L_VIEW_PREVIOUS_TOPIC}</a> &bull; <!-- IF U_VIEW_UNREAD_POST and not S_IS_BOT --><a href="{U_VIEW_UNREAD_POST}">{L_VIEW_UNREAD_POST}</a> &bull; <!-- ENDIF -->{TOTAL_POSTS}
			<!-- IF PAGE_NUMBER --><!-- IF PAGINATION --> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF --><!-- ENDIF --> &bull; <a href="{U_VIEW_NEWER_TOPIC}">{L_VIEW_NEXT_TOPIC}</a>
		</div>
	<!-- ENDIF -->
* if you use this snippet : viewtopic.php?f=9&t=1086&p=6418#p6418
replace with:

Code: Select all

   <!-- IF PAGINATION or TOTAL_POSTS -->
      <div class="pagination">
         <a href="{U_VIEW_OLDER_TOPIC}">{L_VIEW_PREVIOUS_TOPIC}</a> &bull; <!-- IF U_VIEW_UNREAD_POST and not S_IS_BOT --><a href="{U_VIEW_UNREAD_POST}">{L_VIEW_UNREAD_POST}</a> &bull; <!-- ENDIF -->{TOTAL_POSTS}
         <!-- IF PAGE_NUMBER --><!-- IF PAGINATION --> &bull; <a href="{U_LAST_POST}">{L_LAST_POST}</a> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF --><!-- ENDIF --> &bull; <a href="{U_VIEW_NEWER_TOPIC}">{L_VIEW_NEXT_TOPIC}</a>
      </div>
   <!-- ENDIF -->
find:

Code: Select all

	<!-- IF PAGINATION or TOTAL_POSTS -->
		<div class="pagination">
			{TOTAL_POSTS}
			<!-- IF PAGE_NUMBER --><!-- IF PAGINATION --> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF --><!-- ENDIF -->
		</div>
	<!-- ENDIF -->
replace with:

Code: Select all

	<!-- IF PAGINATION or TOTAL_POSTS -->
		<div class="pagination">
			<a href="{U_VIEW_OLDER_TOPIC}">{L_VIEW_PREVIOUS_TOPIC}</a> &bull; {TOTAL_POSTS}
			<!-- IF PAGE_NUMBER --><!-- IF PAGINATION --> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF --><!-- ENDIF --> &bull; <a href="{U_VIEW_NEWER_TOPIC}">{L_VIEW_NEXT_TOPIC}</a>
		</div>
	<!-- ENDIF -->
* if you use this snippet : viewtopic.php?f=9&t=1086&p=6418#p6418
replace with:

Code: Select all

   <!-- IF PAGINATION or TOTAL_POSTS -->
      <div class="pagination">
         <a href="{U_VIEW_OLDER_TOPIC}">{L_VIEW_PREVIOUS_TOPIC}</a> &bull; {TOTAL_POSTS}
         <!-- IF PAGE_NUMBER --><!-- IF PAGINATION -->&bull; <a href="{U_LAST_POST}">{L_LAST_POST}</a> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF --><!-- ENDIF --> &bull; <a href="{U_VIEW_NEWER_TOPIC}">{L_VIEW_NEXT_TOPIC}</a>
      </div>
   <!-- ENDIF -->
Refresh template for prosilver.
pic: (box highlighted in red is view last post link,green is view next last topic)
next-first.png
Steve wrote: 14 Nov 2024, 16:45 It's happy bastard day!
User avatar
Oliver
BBCoder III
BBCoder III
Posts: 120
Joined: 07 Mar 2010, 11:55

Re: Next topic,last topic in pagination for prosilver style

Post by Oliver »

Very good job steve.
Locked