Notifications
Clear all

wpForo 1.x.x recent posts

8 Posts
3 Users
3 Likes
793 Views
Posts: 47
Topic starter
(@adriaan)
Trusted Member
Joined: 3 years ago

Hi there,

Is it possible to set the recent posts so that posts that are older than 3 months are not displayed?

best regards

7 Replies
Posts: 1079
(@tutrix)
Noble Member
Joined: 3 years ago

@adriaan

read this post > Change Recent Topics Time Limit

Reply
Posts: 47
Topic starter
(@adriaan)
Trusted Member
Joined: 3 years ago

Hey,

Thank you.
I added this code to my snippet plugin:

add_filter('wpforo_recent_posts_limit', function($days){return 30;} );

but i cant see changes. should i clear the forum cache?

Reply
1 Reply
(@tutrix)
Joined: 3 years ago

Noble Member
Posts: 1079

@adriaan 

yes, after each change on files/templates, you need to clear the cache

Reply
Posts: 47
Topic starter
(@adriaan)
Trusted Member
Joined: 3 years ago

Hey

I did that but unfortunately there is no change

or does it have to be in the functions.php of the theme? I have now put that into a plugin for code snippets

Reply
1 Reply
Admin
(@chris)
Joined: 2 years ago

Support Team
Posts: 3653

@adriaan,

Yes, it must be in your Active themes functions.php file.

Reply
Posts: 47
Topic starter
(@adriaan)
Trusted Member
Joined: 3 years ago

Hey

 

I copied it into the theme's functions.php and cleared the forum's cache, but that didn't change anything

Reply
1 Reply
(@tutrix)
Joined: 3 years ago

Noble Member
Posts: 1079

@adriaan 

try a lower value instead of 30

Reply