"Mark all read" in bottom

Get help with installation and running phpBB 3.2.x here. Please do not post bug reports, feature requests, or extension related questions here.
Post Reply
rajpb
Registered User
Posts: 29
Joined: Sat Mar 24, 2018 11:12 pm

"Mark all read" in bottom

Post by rajpb » Tue Apr 10, 2018 7:45 am

In viewforum_body in prosilver there are two" pagination" blocks - one above posts and one below.
In both is line which should display "mark all read" function.

Code: Select all

...
		<!-- IF not S_IS_BOT and U_MARK_TOPICS and .topicrow --><a href="{U_MARK_TOPICS}" class="mark" accesskey="m" data-ajax="mark_topics_read">{L_MARK_TOPICS_READ}</a> &bull; <!-- ENDIF -->
....
			<!-- IF not S_IS_BOT and U_MARK_TOPICS and .topicrow --><a href="{U_MARK_TOPICS}" data-ajax="mark_topics_read">{L_MARK_TOPICS_READ}</a> &bull; <!-- ENDIF -->
...
But works only first one. Why?
Attachments
mark_read.jpg

User avatar
JimA
Community Team Leader
Community Team Leader
Posts: 7585
Joined: Thu Jul 31, 2008 5:54 am
Location: The Netherlands
Name: Jim Mossing Holsteyn
Contact:

Re: "Mark all read" in bottom

Post by JimA » Tue Apr 10, 2018 9:34 am

That's because the "Unread posts" page doesn't use the viewforum_body.html template, that's only used inside actual forums. :)

As unread posts is a variant of search.php it makes use of the search_results.html template file and there the Mark posts read code is only available at the top pagination section and not at the bottom one. To change that, look for the following code (lines 229 - 236):

Code: Select all

	<div class="pagination">
		{SEARCH_MATCHES}
		<!-- IF .pagination -->
			<!-- INCLUDE pagination.html -->
		<!-- ELSE -->
			 &bull; {PAGE_NUMBER}
		<!-- ENDIF -->
	</div>
Replace it with:

Code: Select all

	<div class="pagination">
	<!-- IF U_MARK_ALL_READ --><a href="{U_MARK_ALL_READ}" class="mark-read" accesskey="m">{L_MARK_ALL_READ}</a> &bull;<!-- ENDIF -->
		{SEARCH_MATCHES}
		<!-- IF .pagination -->
			<!-- INCLUDE pagination.html -->
		<!-- ELSE -->
			 &bull; {PAGE_NUMBER}
		<!-- ENDIF -->
	</div>
I didn't test this, but it should work. Re-apply after every update. Please let me know if you run into any problems.
Also, for the code changes to take effect, you'll first have to purge the cache at the front page of the ACP. Good luck! :)
Image Jim Mossing Holsteyn - Community Team Leader
Knowledge Base | Documentation | Board rules

If you're having any questions about the rules/customs of this website, feel free to drop me a PM.

rajpb
Registered User
Posts: 29
Joined: Sat Mar 24, 2018 11:12 pm

Re: "Mark all read" in bottom

Post by rajpb » Tue Apr 10, 2018 10:11 am

Thank You!

Post Reply

Return to “[3.2.x] Support Forum”