Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: Nathaniel on September 22, 2008, 07:20:01 PM

Title: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on September 22, 2008, 07:20:01 PM
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=1414)

Recent Topics On "Recent Posts" Page 1.2 by Nathaniel
Overview
This mod replaces the list of recent posts/messages which are displayed for the 'Recent Posts' action with a list of recent/new topics (default) or recently updated topics. The template remains completely the same. It also changes the 'View the most recent posts on the forum.' link in the info center so that it says 'recent topics' or 'recently updated topics' instead of 'recent posts'.

This mod has two modes:
1) 'Recent/New Topics' - Displays a list of the topics which have been created recently, in order of their creation. The first message of each topic will be shown. (default)
2) 'Recently Updated Topics' - Displays a list of the topics which have been recently updated, in order of the the most recent post in each respective topic. The last or most recent message of each topic will be shown.

You can change the mode setting in the admin area:
For SMF 1.1.x: Admin -> Configuration -> Features and Options -> Layout and Options -> "Recent Topics On "Recent Posts" Page mode".
For SMF 2: Admin ->  Configuration -> Modification Settings -> "Recent Topics On "Recent Posts" Page mode".

SMF Version Support
This mod is officially supported for SMF 2.0 and above only. Below is a list of available versions of this mod and the previous versions of SMF that they supported. Use them at your own risk. The mod author will not be supporting or upgrading this mod in any way for versions of SMF below 2.0.

Version 1.1: SMF 1.1.x and versions of SMF 2 below SMF 2 RC4.
Version 1.2: SMF 2 RC4 and above.

Donate
If this mod has helped you, then feel free to support the developer by Donating (https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=VCFQ7MJNVXLLA&lc=AU&item_name=Donation&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted). Any amount of money is welcome.

Custom Themes Changes:
These edits are only necessary if your custom theme has a 'BoardIndex.template.php' file, otherwise the mod should work automatically. The edits below are applied to your 'BoardIndex.template.php' file.

Code ("Find (SMF 1.1.x)") Select
<a href="', $scripturl, '?action=recent">', $txt[234], '</a>

Code ("Find (SMF 2)") Select
<a href="', $scripturl, '?action=recent">', $txt['recent_view'], '</a>

Code ("Replace") Select
<a href="', $scripturl, '?action=recent">', !empty($modSettings['RecentTopicsOnRecentPostsPage_mode']) && $modSettings['RecentTopicsOnRecentPostsPage_mode'] == 'updated' ? $txt['RecentTopicsOnRecentPostsPage_updated_linktext'] : $txt['RecentTopicsOnRecentPostsPage_linktext'], '</a>

Version Changes
v1.2 - 5 November 2010
Updated for SMF 2 RC4.

v1.1 - 20 November 2009
Added support for SMF 2 RC2.
Added the mode changing setting, and the new "Recently Updated Topics" mode as requested by Akyhne.

v1.0 - 18 September 2008
Original Mod release.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: neil h on September 23, 2008, 07:36:05 AM
Great stuff LHVWB!

Installed without a hitch.

One request for v.2 - A 'number of replies' field.

Many, many thanks,

Neil

See it working here: frameforum dot org slash forum3
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on September 23, 2008, 09:02:25 PM
I am glad that you like the mod! :D

Its not a bad suggestion, although I don't think that I will add it to the mod because it would have to change the layout of that template (which is a pain). I am however happy to help you change your template if you can tell me exactly where you want it on that page.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: RoarinRow on September 23, 2008, 11:54:38 PM
cool, gotta try this out   8)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: neil h on September 24, 2008, 02:46:20 AM
Quote from: LHVWB on September 23, 2008, 09:02:25 PM
I am glad that you like the mod! :D

Its not a bad suggestion, although I don't think that I will add it to the mod because it would have to change the layout of that template (which is a pain). I am however happy to help you change your template if you can tell me exactly where you want it on that page.

I would put it just after 'Started by XXX'  'Last post by xxx'

like this:
'Started by XXX' : 'Last post by xxx' :  Replies NNN

Is it possible to do this? would be cool!

Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on September 24, 2008, 05:05:18 AM
@neil h,
Which version of SMF do you have? That should definitely be possible, but the edits will change depending on the version of SMF.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: zaabava on September 24, 2008, 05:14:24 AM
Photos Modn ,plesase
Title: Re: Recent Topics On "Recent Posts" Page
Post by: neil h on September 24, 2008, 06:48:23 AM
Quote from: LHVWB on September 24, 2008, 05:05:18 AM
@neil h,
Which version of SMF do you have? That should definitely be possible, but the edits will change depending on the version of SMF.

sorry, my bad. I'm on v.1.16
Title: Re: Recent Topics On "Recent Posts" Page
Post by: neil h on September 24, 2008, 06:49:36 AM
Quote from: zaabava on September 24, 2008, 05:14:24 AM
Photos Modn ,plesase

frameforum.org/forum3/index.php (http://frameforum.org/forum3/index.php) has the mod installed.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: zaabava on September 24, 2008, 07:52:21 AM
Thenks!!
Title: Re: Recent Topics On "Recent Posts" Page
Post by: gigz09 on September 27, 2008, 01:39:41 PM
i dont know why but it seems it doesnt have effect in my forum, im using 1.1.6 with default template.. but it doesnt change at all.. is there any settings do i have to enable for me to use this?

TIA
Title: Re: Recent Topics On "Recent Posts" Page
Post by: neil h on September 28, 2008, 04:05:48 AM
Quote from: gigz09 on September 27, 2008, 01:39:41 PM
i dont know why but it seems it doesnt have effect in my forum, im using 1.1.6 with default template.. but it doesnt change at all.. is there any settings do i have to enable for me to use this?

TIA

where's your forum?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: gigz09 on September 28, 2008, 07:03:14 PM
here it is:

http://electronicstup.gzxlab.com (http://electronicstup.gzxlab.com)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: neil h on September 29, 2008, 03:01:03 AM
Quote from: gigz09 on September 28, 2008, 07:03:14 PM
here it is:

http://electronicstup.gzxlab.com (http://electronicstup.gzxlab.com)

I couldn't sign up because I'm not a student, but I'd say you've got 'Recent Posts' switched off in your admin panel. What version of SMF are you using?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 02, 2008, 06:56:03 AM
I just tried this mod, but it gives me the first post in a topic, not the the newest. Isn't that the idea?

What I'm trying to say is that it shows me the most recent topics, but with the first post of the topic and not the newest post.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 02, 2008, 07:06:38 AM
@akyhne,
No, the idea is that it shows a list of the lastest topics that have been posted (thus it shows the first post), not the lastest updated topics. It could however be edited so that it shows the lastest post, or even the 'Most Recently Updated Topics' instead of the 'Most Recent Topics'. I could post the edits if you want, although I will need to know your SMF version.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 02, 2008, 07:19:51 AM
People are using the most recent posts to view the most recent posts. I think your mod is great because it "hides" all new posts in a topic. I have a forum with a high post count (1.1.6) and people are complaining that there are to many posts to read in the most recent posts.

But they can't use the first post to anything, only the latest. So it would be great if you made the mod to show the latest, or even an option in admin part to choose wether it should show the most recent post of the topic or the first post.

I'll take your code with open arms.

Aky
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 02, 2008, 07:39:25 AM
Open up your 'Recent.php' file, find the code below:
   $request = db_query("
      SELECT m.ID_MSG
      FROM ({$db_prefix}messages AS m, {$db_prefix}topics AS t, {$db_prefix}boards AS b)
      WHERE b.ID_BOARD = m.ID_BOARD
         AND m.ID_MSG = t.ID_FIRST_MSG


Replace with this code:
   $request = db_query("
      SELECT m.ID_MSG
      FROM ({$db_prefix}messages AS m, {$db_prefix}topics AS t, {$db_prefix}boards AS b)
      WHERE b.ID_BOARD = m.ID_BOARD
         AND m.ID_MSG = t.ID_LAST_MSG


Please note, that its still just showing a list of the most recent topics, just with the last post instead of the first post, the edit will be slightly different if you want the 'Most Recently Updated topics'.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 02, 2008, 07:46:24 AM
Hmm, it must be the 'most recently topics' I'm looking for.

What my users requires is this:
When they visit the "recent posts", they get all the posts. So if a topic has 10 new posts, they are shown. They just want the latest post shown from each topic.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 02, 2008, 08:01:51 AM
Thats odd, the code I posted should actually work. It should show the lastest posts, but only the lastest from each topic.... Its amazing what you can archieve by changing a single part of an SQL query. ;)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 02, 2008, 08:10:45 AM
I didn't test it as i understood it would give me something else than I wanted.

Did i get this part wrong? "Please note, that its still just showing a list of the most recent topics, just with the last post instead of the first post, the edit will be slightly different if you want the 'Most Recently Updated topics'. "
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 02, 2008, 08:23:22 AM
No actually I got it wrong. ;D

I actually didn't realise that making such a small edit would do exactly what you want, that edit should make the page into a 'Most Recently Updated Topics' page, although it won't change any of the language strings. ;)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 02, 2008, 08:28:39 AM
It works as it should.
I get one post from each topic now, but the most recent instead of the first (that's the idea with most recent ain't it ;) ).

Thanks a lot. You should concider the option I mentioned to make people being able to change wether they want the first or the latest post shown.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 02, 2008, 08:31:52 AM
I did have a think about that option when I first created this mod, although I decided that I was too lazy to actually implement it. ;) I might put it in, because its sooo easy, but it will probably wait until I have to update it for the next versions of SMF (whenever they come). ;)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 02, 2008, 08:41:04 AM
I would actually think of keeping the old link and add your mod, so that people had both choices - view recent posts and wiev recent topics.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 02, 2008, 08:43:59 AM
Wouldn't it just be to add 'recent' => array('Recent.php', 'RecentTopics'), in the index.php file and then make a copy of the function
function RecentPosts() and rename it  function RecentTopics(), then call it with a new link in BoardIndex.template.php?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 02, 2008, 08:50:49 AM
Yes, that should work fine. I gave it a test and it worked well. ;)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 02, 2008, 08:55:10 AM
'recent' => array('Recent.php', 'RecentTopics')
should of course be
'recentTopic' => array('Recent.php', 'RecentTopics')
or similar.

.. or how did you do it?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 02, 2008, 09:02:43 AM
I just used this code, but 'recentTopic' should work. ;)
'recent2' => array('Recent.php', 'RecentTopics')
Title: Re: Recent Topics On "Recent Posts" Page
Post by: gigz09 on October 03, 2008, 08:06:19 AM
Quote from: akyhne on October 02, 2008, 06:56:03 AM
I just tried this mod, but it gives me the first post in a topic, not the the newest. Isn't that the idea?

What I'm trying to say is that it shows me the most recent topics, but with the first post of the topic and not the newest post.

im using 1.1.6

you can use my test account

user: test
password: 369369369
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 03, 2008, 10:23:35 AM
???
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Akyhne on October 03, 2008, 10:25:52 AM
LHVWB: It worked great for me. I removed your mod and made the changes manually. Are you going to change the mod? I hate making manual changes as it is hard to recover everything when upgrading to 2.0
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 03, 2008, 08:46:54 PM
Well, like I said. When I next upgrade this mod, for SMF version compatibility I will try to remember to add this feature as well. ;)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: gigz09 on October 04, 2008, 12:49:53 AM
anyone can help me? how do i activate this mod? im using 1.1.6 in my site..
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 04, 2008, 01:47:11 AM
@gigz09,
As far as I can see, the mod works fine on your website. Click on the 'View the most recent topics on the forum.' link in the information center at the bottom of your forum and SMF will show you a list of the most recent topics.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: gigz09 on October 04, 2008, 02:44:43 AM
Quote from: LHVWB on October 04, 2008, 01:47:11 AM
@gigz09,
As far as I can see, the mod works fine on your website. Click on the 'View the most recent topics on the forum.' link in the information center at the bottom of your forum and SMF will show you a list of the most recent topics.

oh im really sorry i thought this mod works same as the advance recent post.. im so sorry...
Title: Re: Recent Topics On "Recent Posts" Page
Post by: katib on October 07, 2008, 01:48:04 PM
LHVWB
thank you very much
please! how can I display those recent  topics in scrolling fashion with marquee tag ?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on October 07, 2008, 11:14:12 PM
@katib,
Can you explain that a bit more? Which parts of the page do you want to scroll?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: katib on October 08, 2008, 09:40:00 AM
//
Quote from: LHVWB on October 07, 2008, 11:14:12 PM
@katib,
Can you explain that a bit more? Which parts of the page do you want to scroll?
thank you very much for help
I found a way to doing it using
include('SSI.php');
$posts = ssi_recentTopics(10, null, 'vivo');
I have posted ir here
http://www.simplemachines.org/community/index.php?topic=266701.0
in arabic section so other users my find it usefull
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on December 21, 2008, 03:10:17 AM
Tested Compatibility with SMF 1.1.7, the mod page has been updated accordingly.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: RickJ on May 22, 2009, 07:28:54 AM
I installed the Mod to SMF 1.1.9 and nothing has changed.  Any suggestions?  Thank you!
Title: Re: Recent Topics On "Recent Posts" Page
Post by: RickJ on May 27, 2009, 07:24:06 AM
I hope it's not too early to bump this :)
Any suggestions for making this mod work on 1.1.9?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on May 27, 2009, 07:39:50 AM
Bumping can be good. I don't have much time for support, so I tend to miss posts. ;)

This mod should work for SMF 1.1.9 (and all 1.1.x versions), but I haven't tested it for that specific version.

Can you post a link to your forum?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: RickJ on May 27, 2009, 07:45:54 AM
Thanks, Nathaniel.  Here it is: http://www.chnetwork.org/forum

We're using the Classic YaBB Theme.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on May 27, 2009, 08:00:07 AM
The mod appears to be working as its meant to. Although you could perform the edit under 'Custom Themes Changes' (in the first post of this topic) to change the text string in the information center on your home page.

Your recent page ('http://www.chnetwork.org/forum/recent/') is showing the latest topics, for each topic the first post of that topic is shown.

If you want to show the latest post from each topic, instead of the first post, then read the post below:
http://www.simplemachines.org/community/index.php?topic=263576.msg1732879#msg1732879
Title: Re: Recent Topics On "Recent Posts" Page
Post by: RickJ on May 27, 2009, 08:14:28 AM
Oh, I see now.  I thought that it automatically changed the text string in the information center.  I'm sorry, Nathaniel - for not paying attention closer.  The "Overview" of the mod seems to imply that installing the mod changes the text string without using the Custom Themes Changes. 

Thank you, Nathaniel.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: selket on June 25, 2009, 03:32:53 PM
Hello, I'm trying to install this mod and I have some problems.
One could be that I have a romanian language installed and not english. When I try to instal this action:
/Themes/default/languages/Modifications.english-utf8.php  is marked as "skiped file'.
Also, after instaling when clicking on "show most recent posts" it only shows me recent created topics, recent being no more than half a day. Can I make "recent" to be like a day long and also have all topics in which there were added new messages, not only new created topics?
Another question is that if it is possible to have only a list of the new updated topics and the enumeration of the pages 1 2 3... x,  without the last/first post shown.
My theme has a BoardIndex.template.php file, but when I change the code as you say the "'View the most recent posts on the forum.' link on the forum disapears. :(
If it helps, I have Pretty urls installed.
What is it I do wrong?
Thank you.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: khaleed on September 12, 2009, 01:08:57 PM
Hello Nathaniel,

I'm using your advance recent post mod but the problem is my forum background color is gray and it's make all your recent posts mod title like subject, replies etc cannot been seen. Can you show me how can I change the font color for the recent post mod title.  I attach the picture for your reference.

thanks
Title: Re: Recent Topics On "Recent Posts" Page
Post by: khaleed on September 13, 2009, 10:03:33 AM
bump !  8)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: khaleed on September 14, 2009, 03:40:09 AM
bump
Title: Re: Recent Topics On "Recent Posts" Page
Post by: khaleed on September 15, 2009, 09:24:44 PM
bum..... :(
Title: Re: Recent Topics On "Recent Posts" Page
Post by: khaleed on September 19, 2009, 12:02:55 PM
 >:( >:(  Somebody anybody......
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Bec on October 06, 2009, 07:20:22 PM
hmmm suppose its not a good time for me to be asking for help....

I am ideally wanting the most recent topics to show the most recent topics that have been updated (not a post from that topic) so ideally just a list of the latest topics which my members can then click on and it takes them into that topic..... can this be done?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: mikev on November 15, 2009, 01:06:11 PM
Quote from: Bec on October 06, 2009, 07:20:22 PM
I am ideally wanting the most recent topics to show the most recent topics that have been updated (not a post from that topic) so ideally just a list of the latest topics which my members can then click on and it takes them into that topic..... can this be done?

I'd like to second this request.  This mod is almost exactly what I'm looking for, I've got it working on RC2, but if there was a way to have action=recent show only topics, and not show the first post, it would be absolutely perfect.  Is there an easy way to do this?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Bec on November 17, 2009, 08:20:20 AM
mikev, i found another mod which gives me exactly what i wanted - http://custom.simplemachines.org/mods/index.php?mod=654

you can see it in action on my site - {url removed}
Title: Re: Recent Topics On "Recent Posts" Page
Post by: mikev on November 17, 2009, 11:18:50 AM
I'm running RC2, that mod doesn't work anymore.  Thank you though :)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Bec on November 17, 2009, 03:02:55 PM
you're welcome. just hit them up for an update!
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on November 19, 2009, 04:03:19 AM
Quote from: selket on June 25, 2009, 03:32:53 PM
Hello, I'm trying to install this mod and I have some problems.
One could be that I have a romanian language installed and not english. When I try to instal this action:
/Themes/default/languages/Modifications.english-utf8.php  is marked as "skiped file'.
Also, after instaling when clicking on "show most recent posts" it only shows me recent created topics, recent being no more than half a day. Can I make "recent" to be like a day long and also have all topics in which there were added new messages, not only new created topics?
Another question is that if it is possible to have only a list of the new updated topics and the enumeration of the pages 1 2 3... x,  without the last/first post shown.
My theme has a BoardIndex.template.php file, but when I change the code as you say the "'View the most recent posts on the forum.' link on the forum disapears. :(
If it helps, I have Pretty urls installed.
What is it I do wrong?
Thank you.

Add the code below into your '/Themes/default/languages/Modifications.romanian.php' file:
$txt['RecentTopicsOnRecentPostsPage_actiontitle'] = 'Recent Topics';
$txt['RecentTopicsOnRecentPostsPage_linktext'] = 'View the most recent topics on the forum.';


You will need to translate the 'Recent Topics' and  'View the most recent topics on the forum.' text.

Quote from: khaleed on September 12, 2009, 01:08:57 PM
Hello Nathaniel,

I'm using your advance recent post mod but the problem is my forum background color is gray and it's make all your recent posts mod title like subject, replies etc cannot been seen. Can you show me how can I change the font color for the recent post mod title.  I attach the picture for your reference.

thanks

Apologies about the wait, although you should never bump a support request that frequently, once every 24 hrs is more than enough. Do a search for 'RecentTopicsOnRecentPostsPage_linktext' in your '/Themes/{themename}/BoardIndex.template.php' file, you should be able to add the necessary HTML code there, so that the color is correct. If you need help, then attach that file.

Quote from: Bec on October 06, 2009, 07:20:22 PM
hmmm suppose its not a good time for me to be asking for help....

I am ideally wanting the most recent topics to show the most recent topics that have been updated (not a post from that topic) so ideally just a list of the latest topics which my members can then click on and it takes them into that topic..... can this be done?

Sure it can be done, although that would involve changing the template. Its not something that I intend to add to this mod, I would suggest that you try asking in the Graphics and Templates (http://www.simplemachines.org/community/index.php?board=34.0) board, for help with editing the 'Recent.template.php' file.

Quote from: mikev on November 17, 2009, 11:18:50 AM
I'm running RC2, that mod doesn't work anymore.  Thank you though :)

Ask them to update the mod, not really something that is going to be added to this mod, although you could customize the template, and then get the same effect by using this mod.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on November 19, 2009, 05:03:49 PM
v1.1 - 20 November 2009
Added support for SMF 2 RC2.
Added the mode changing setting, and the new "Recently Updated Topics" mode as requested by Akyhne.

I decided to add the feature request from Akyhne, because it was easy and makes the mod more customizable. :)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: b4pjoe on November 20, 2009, 01:42:30 PM
I installed this mod without any errors but it's still showing recent posts instead recent topics. SMF 2.0 RC2. Either option on the 2 screen shots below look the same. Recent Posts instead of Recent Topics. Tried emptying SMF cache. Emptied browser cache. No joy.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on November 20, 2009, 07:14:05 PM
@joec88,
Could you please post a link to your website? Those screenshots aren't particularly useful, as they don't show what is happening on your recent page. ;)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: b4pjoe on November 20, 2009, 09:24:41 PM
Quote from: Nathaniel on November 20, 2009, 07:14:05 PM
@joec88,
Could you please post a link to your website? Those screenshots aren't particularly useful, as they don't show what is happening on your recent page. ;)

Thanks for taking a look...

http://www.b4print.com/forum

Attached is a shot of the Info Center on the Board Index where it is showing Recent Posts instead of Recent Topics.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: erdem86 on November 29, 2009, 02:43:25 PM
Hi,

I want to exclude some boards from appearing in recent posts area.

How can I do it?

In SSI,

something like

<?php
     ssi_recentTopics
($num_recent 5$exclude_boards = array(1,4), $output_method 'echo');
?>


works.. But how can I do it in your mod?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on November 06, 2010, 07:37:46 AM
v1.2 - 5 November 2010
Updated for SMF 2 RC4.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: YaPaY on December 17, 2010, 04:18:07 AM
Thanks for great mod but with these for me useless.

I'm searching for a long while a mod completely recent topics instead of recent posts. I do not want to click any link and see messages. I need only change last posts section with last topics.

Everything must be same only I can see recent topics list.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on December 22, 2010, 11:50:11 PM
@YaPaY,
Have a go at editing the "/Themes/{themename}/Recent.template.php" file, that contains the templates for that area.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: YaPaY on December 23, 2010, 02:15:07 AM
Quote from: Nathaniel on December 22, 2010, 11:50:11 PM
@YaPaY,
Have a go at editing the "/Themes/{themename}/Recent.template.php" file, that contains the templates for that area.
I Can not edit the file. I do not know php, unfortunately.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: aw06 on January 21, 2011, 11:23:04 AM
Nice mod ... I Installed it and it's working and giving no errors.. But i have a small issue, on the board index it now shows 2 links.. One is active and one it the original link ..

eg...
View the most recent topics on the forum.View the most recent posts on the forum.

See Pic

Any ideas how to fix ???
Title: Re: Recent Topics On "Recent Posts" Page
Post by: aw06 on January 21, 2011, 11:27:19 AM
Not to worry, Fixed it ... had some extra code still in board index..
Title: Re: Recent Topics On "Recent Posts" Page
Post by: impreza on January 21, 2011, 12:53:41 PM
Cool addition, I tested and it looks very good
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Nathaniel on June 16, 2011, 01:59:27 AM
Confirmed that this mod works for SMF 2.0 final.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: dzembak on January 25, 2012, 05:24:49 AM
Does not work on 1.1.16. Nothing has changed after mod install. Files are edited, but mod seems inactive. I`ve tried both modes for this mod at the Admin panel.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 12:08:10 PM
I want to change the link at the bottom from "Job Postings" to "See more." Where do I make the changes in the code? Please bear in mind that I'm hoping for a copy and paste solution. Here's the link to the forum: http://www.kilndrying.org/

I'm using the latest version of SMF.

Great mod, by the way.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: kat on July 11, 2012, 03:38:22 PM
Hi, Wendy.

Have you got the right mod, here?

I just looked at the parser, for this mod. I can't find "Job Postings" anywhere. :(
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 03:48:07 PM
Sorry, the mod is "Recent Topics On "Recent Posts" Page" and the forum I'm using it on is kilndrying (dot) org.

If you hop over there you'll see that at the bottom of each post on the widget are the words, "[Job Postings]." I want to change those words to "See more," per the client's request. I don't know which bit of code to change. When I tried it myself I broke the mod and had to reinstall it.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: kat on July 11, 2012, 03:52:56 PM
Quote from: wendycroft on July 11, 2012, 03:48:07 PM
If you hop over there you'll see that at the bottom of each post on the widget are the words, "[Job Postings]."

Um... Nope.

Can't see that here:

http://www.kilndrying.org/dry-kiln-maintenance/7/plugged-wet-bulb-lines/434/

Although, I CAN on the right, under "Job Opportunities".

Is it visible to guests?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 04:01:54 PM
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi43.servimg.com%2Fu%2Ff43%2F15%2F33%2F22%2F44%2Fkilndr10.jpg&hash=889f4f763ed4755858a716def5151c89b4427f52)

It's near the bottom on your right. I've taken a screenshot of the index page to show you what to look for, and put a red box around the parts I'm trying to change.

The widget is working as intended, it's the words [Job Postings] I want to change. Sorry for not being clearer.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: kat on July 11, 2012, 04:10:33 PM
I have a feeling that that's Simple Portal, isn't it?

I inspected the element and I see this:

<div class="sp_block">
<table class="sp_fullwidth">
<tbody>
<tr>
<td class="sp_recent_icon sp_center">
<td class="sp_recent_subject">
<a href="http://www.kilndrying.org/job-postings/11/boiler-kiln-relief/436/msg584;topicseen#new">
<br/>
[
<a href="http://www.kilndrying.org/job-postings/11/">Job Postings</a>


"sp" is Simple Portal, I believe.

An html block, perhaps?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Arantor on July 11, 2012, 04:14:11 PM
However that block was created is important - it's taking the 'Job Postings' from the name of the board where the topics are posted...
Title: Re: Recent Topics On "Recent Posts" Page
Post by: kat on July 11, 2012, 04:17:55 PM
Doesn't:

<a href="http://www.kilndrying.org/job-postings/11/">Job Postings</a>

produce the text? (Just curious)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 04:26:21 PM
The only files that come with the mod are XML ones so I need to know which bit of XML to change. Shall I post the code here?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: kat on July 11, 2012, 04:32:04 PM
I don't think that has anything to do with this mod, myself.

As I said, I think it's a Simple Portal block.

Either way, I think, whatever it is, it's pulling the name from the title of the "Job Postings" board.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Arantor on July 11, 2012, 04:39:30 PM
That's generated from the query that gets everything - you're only seeing the result HTML, but it's originally generated from the board where the topics are posted. Rename the board, it'll change the text.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 05:17:30 PM
Thank you, chaps, but I don't think I'll be able to convince the client to let me change the name of the board to "See more."
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Arantor on July 11, 2012, 05:23:28 PM
In which case it'll be a rewrite of the mod of sorts - except that it's in a Simple Portal block, not necessarily using this mod... how exactly is that block set up in SP?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 05:27:39 PM
It's a mod that lets you change the Recent Posts news block to Recent Topics. It shows up in Blocks in Simple Portal. The best way to figure it out would be to install it on your own forum and work from there. You're the one with the brains.

Where's Nathaniel? As the writer he'd have the answers. I can't PM him because he'd delete it. He expects me to come here for help.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Arantor on July 11, 2012, 05:30:01 PM
Um, no, that's not how it works.

This mod modifies the master recent posts stuff, and does not interact with SP at all, so that block in SP is down to SP. (I know, I checked how the mod works.)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 05:39:33 PM
I'm a noob hoping for a cut and paste solution. What can I do? There's no way to change this thing in Blocks or SP.

Or is there? How can I change the text?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Arantor on July 11, 2012, 05:42:01 PM
So go into SP's configuration and take a look at the list of blocks that are defined and see exactly how that one block is set up...
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 05:49:00 PM
Screenshots:

The blocks menu
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi43.servimg.com%2Fu%2Ff43%2F15%2F33%2F22%2F44%2Fkilndr11.jpg&hash=2fa8326d35e1c31790cbb1b2b58537598a3165d3)

The "Recent Topics" block menu

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi43.servimg.com%2Fu%2Ff43%2F15%2F33%2F22%2F44%2Fkilndr10.png&hash=5d742b5b053081167b1fdc3f3b6ab055bb8deeb8)

This is all I've got to work with. I thought the change would have to be made to the code. There's no opportunity to change it here and since you said you know how it works...
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Arantor on July 11, 2012, 07:17:04 PM
Yes, the change will be to the code. Except the code concerned is not this mod.

I know how the mod works - the mod doesn't have the options provided by the screenshot you've shown me. It is going to be a code change to the depths of SP somewhere instead...
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 11, 2012, 07:27:29 PM
Where and how? I have no idea where to start.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: wendycroft on July 12, 2012, 06:28:21 AM
New plan: I need to write a mod to do this. Since neither of you know how to change the mod as it is, and Nathaniel has dropped off the radar, how can I make one myself? I've only got XML files. Do I use those?
Title: Re: Recent Topics On "Recent Posts" Page
Post by: jack208 on July 18, 2018, 05:44:14 PM
Has anybody had this mod working on 2.0.15? I've installed and it does not seem to work (still showing recent posts instead of topics). Nothing appears broken, and I checked the php files to confirm the edits were made (when the mod installed).
Title: Re: Recent Topics On "Recent Posts" Page
Post by: GigaWatt on July 18, 2018, 06:32:07 PM
If you're just looking for a mod that will show the recent topics, you could use this (https://custom.simplemachines.org/mods/index.php?mod=3856) one. It hasn't received support for a while, but I can confirm that it works correctly in 2.0.15 ;).

Sorry, just checked, my mistake :P, the author is still pretty much active ;).
Title: Re: Recent Topics On "Recent Posts" Page
Post by: jack208 on July 18, 2018, 07:52:11 PM
Quote from: GigaWatt on July 18, 2018, 06:32:07 PM
If you're just looking for a mod that will show the recent topics, you could use this (https://custom.simplemachines.org/mods/index.php?mod=3856) one.

Thanks GGWatt.

Yes I'd installed this mod earlier but it's doing something different to what I wanted. It does work on ver 2.0.15. It's showing a separate block of Recent Topics - so won't work with themes that are using the default Recent Posts block. It's also showing all 100 recent topics where I need to display only say the 10 most recent.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: Pipke on July 19, 2018, 02:29:38 AM
Quote from: jack208 on July 18, 2018, 07:52:11 PM
so won't work with themes that are using the default Recent Posts block.

Why would it not work if thats enabled i dont get that part, it should just do the job.

Quote from: jack208 on July 18, 2018, 07:52:11 PM
It's also showing all 100 recent topics where I need to display only say the 10 most recent.

that is asked before on this msg (https://www.simplemachines.org/community/index.php?topic=522114.msg3919817#msg3919817) it can be fixed with this msg (https://www.simplemachines.org/community/index.php?topic=522114.msg3919833#msg3919833)
Title: Re: Recent Topics On "Recent Posts" Page
Post by: GigaWatt on July 19, 2018, 02:11:44 PM
Quote from: jack208 on July 18, 2018, 07:52:11 PM
Yes I'd installed this mod earlier but it's doing something different to what I wanted. It does work on ver 2.0.15. It's showing a separate block of Recent Topics - so won't work with themes that are using the default Recent Posts block.

Could you post a screen shot of what seems to be bothering you about the mod? Maybe a before and after one as well and how you'd like it to reflect on the theme ;).

Quote from: jack208 on July 18, 2018, 07:52:11 PM
It's also showing all 100 recent topics where I need to display only say the 10 most recent.

I understand, it kind of bothered me too that I can't set the maximum number of recent topics to display, but hey, Pipke posted a solution and besides, you could always set the number of topics per page to 10 and let the mod just list the rest of the "recent" topics on the rest of the pages ;). That's what I did :). Most of my members don't even notice that there is a page count in the recent topics section, trust me, it'll be like the page count doesn't exist ;).
Title: Re: Recent Topics On "Recent Posts" Page
Post by: jack208 on July 19, 2018, 05:20:39 PM
Hi Pipke, appreciate you popping in here and give me a reply! Firstly I hope that my comments earlier above is not meant to say your Recent Topics on BoardIndex mod is bad... in fact I was using it to list recent topics on our board when we were still using the Default Curve theme. :)

While it would be good to have limits of 10 topics etc, I'm fine with the paginations (though obviously reading your reply above, if there's a manual edit that can allow the max 10 items to be applied without needing to page 100 topics, that would even be better). Compared with the default Recent Posts block which appears at the bottom of the page and terribly formatted, your mod is definitely a step up (beside the point that it switches from Posts to Topics).

However I've just installed the STUDIO theme into the site; and that theme has nicely re-arranged the default Recent Posts block to the right-nav bar and properly formatted (see #2 in the attached pic) which I think is a huge improvement over the default style. The only issue I've now is that it's showing posts (it's default behavior) instead of topics. Hence my search for mod like this from Nathaniel that supposedly switch from posts to topics for the default Recent Posts block.

I've re-installed your mod - just to see how it looks/works with the STUDIO theme - and attached is the result. It still works nicely (programmatically), and it's adding a new section at the top of the page (which is how it is designed - just that it's not my use case). There are some styling issues  as you can see from the screencap but these are relatively minor and can be fixed if anyone really wants to use this mod with the STUDIO theme.

So back to TL:DR
- we are now using STUDIO as our default theme (and we are on ver 2.0.15)
- we like how they changed the default Recent Posts block and moved it up from the bottom of the page where it languished to the right-nav bar except... we want it to show Topics instead of Posts
- the Recent Topics on BoardIndex mod works on ver 2.0.15 and also in STUDIO theme (as in the attached pic, some minor CSS styling issues to resolve) but that's not what we were looking for (as it replaces the default block with it's own at-top-of-page block and does not fit in with the Studio theme).

Title: Re: Recent Topics On "Recent Posts" Page
Post by: jack208 on July 19, 2018, 05:25:27 PM
Quote from: Pipke on July 19, 2018, 02:29:38 AM
Why would it not work if thats enabled i dont get that part, it should just do the job.

No, I meant the "default Recent Posts block" is not switching from posts to topics even after I'd installed this "Recent Topics on Recent Posts" mod; not your Recent Topics on BoardIndex mod. :P

Quote from: Pipke
that is asked before on this msg (https://www.simplemachines.org/community/index.php?topic=522114.msg3919817#msg3919817) it can be fixed with this msg (https://www.simplemachines.org/community/index.php?topic=522114.msg3919833#msg3919833)

Thanks for this tip. If I'm using back the Recent Topics on BoardIndex mod, I'll surely put this fix in as 10 recent topics are all we need. :) though as I've mentioned we were okay with leaving the pagination as-is as a workaround.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: jack208 on July 19, 2018, 05:46:58 PM
Quote from: GigaWatt on July 19, 2018, 02:11:44 PM
Could you post a screen shot of what seems to be bothering you about the mod? Maybe a before and after one as well and how you'd like it to reflect on the theme ;) .
Thanks for the reply. Just posted the screen shot. Here's another screen shot - with the Recent Topics on BoardIndex switched off so you are seeing the STUDIO them as-is. It's almost perfect for what we need except I wish we can show list of recent topics on the right nav-bar rather than posts.



Title: Re: Recent Topics On "Recent Posts" Page
Post by: GigaWatt on July 19, 2018, 06:19:14 PM
Quote from: jack208 on July 19, 2018, 05:20:39 PM
...(beside the point that it switches from Posts to Topics).

Actually, that was exactly what I was looking for, so Pipke's mod was exactly what I wanted ;).

Quote from: jack208 on July 19, 2018, 05:20:39 PM
The only issue I've now is that it's showing posts (it's default behavior) instead of topics. Hence my search for mod like this from Nathaniel that supposedly switch from posts to topics for the default Recent Posts block.

I haven't actually seen the code for this mod, but I think it might only work with Cruve or Cruve variants (it edits the theme files) and since Studio is very different from Curve, It probably uses it's own code to show the recent posts and thus, the mod can't be applied :S.

Or, you could try uninstalling the mod, then reinstalling it and see if it offers to patch files in Studio. If it does, see if it passes the tests, if it does, install it and see if it works as planned ;).

Quote from: jack208 on July 19, 2018, 05:46:58 PM
Thanks for the reply. Just posted the screen shot. Here's another screen shot - with the Recent Topics on BoardIndex switched off so you are seeing the STUDIO them as-is. It's almost perfect for what we need except I wish we can show list of recent topics on the right nav-bar rather than posts.

Try what I've suggested in the previous paragraph, if it works, great :), if there are errors, don't install it, I'll see if I have time to take a look at the code and see if we could patch Studio manually to show recent topics instead of recent posts ;).
Title: Re: Recent Topics On "Recent Posts" Page
Post by: jack208 on July 19, 2018, 07:26:15 PM
Quote from: GigaWatt on July 19, 2018, 06:19:14 PM
I haven't actually seen the code for this mod, but I think it might only work with Cruve or Cruve variants (it edits the theme files) and since Studio is very different from Curve, It probably uses it's own code to show the recent posts and thus, the mod can't be applied :S.

Or, you could try uninstalling the mod, then reinstalling it and see if it offers to patch files in Studio. If it does, see if it passes the tests, if it does, install it and see if it works as planned ;) .

Try what I've suggested in the previous paragraph, if it works, great :) , if there are errors, don't install it, I'll see if I have time to take a look at the code and see if we could patch Studio manually to show recent topics instead of recent posts ;) .
Oh.. I forgot to mention I've another test member who's set to use the Default Curve theme (as a test/validation) and that user is still seeing recent posts in the default Recent Posts block (which is at the bottom of the page). So it does appear STUDIO is just leveraging on the same block but re-position it to the right nav-bar. I might be wrong though without actually reading the codes.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: GigaWatt on July 19, 2018, 07:58:08 PM
As I said, you could try uninstalling the mod and try installing it again, but this time, if the mod asks to also patch files from the Studio theme, tick the boxes that apply to the Studio theme, check if there are any failed tests, if not, proceed with the reinstall and see if it works ;).
Title: Re: Recent Topics On "Recent Posts" Page
Post by: jack208 on July 19, 2018, 08:38:16 PM
Quote from: GigaWatt on July 19, 2018, 07:58:08 PM
As I said, you could try uninstalling the mod and try installing it again, but this time, if the mod asks to also patch files from the Studio theme, tick the boxes that apply to the Studio theme, check if there are any failed tests, if not, proceed with the reinstall and see if it works ;) .
Yup, had done that earlier when I installed the mod for the 1st time. And in fact, just repeated the steps (uninstall and re-install) again since I was installing the Recent Topic BoardIndex mod for a testrun earlier. Same results ie still showing posts.

The test on STUDIO was marked successful... here's the Install List attached.
I haven't reach out to Gecitli (Studio dev) on this yet becoz the mod is actually not working even on the Default Curve theme so I suspect the issue is not so much STUDIO but rather whether the mod works on ver 2.0.15 (in theory it should).
Title: Re: Recent Topics On "Recent Posts" Page
Post by: GigaWatt on July 20, 2018, 10:50:16 AM
Quote from: jack208 on July 19, 2018, 08:38:16 PM
I haven't reach out to Gecitli (Studio dev) on this yet becoz the mod is actually not working even on the Default Curve theme so I suspect the issue is not so much STUDIO but rather whether the mod works on ver 2.0.15 (in theory it should).

I forgot to ask that and that seems to answer the question. If it's not working in Curve, it probably won't work in any other theme :S.

I could probably have a look and see if I can get the mod working, since the author hasn't logged in since 2014, but I can't promise anything :S.
Title: Re: Recent Topics On "Recent Posts" Page
Post by: jack208 on July 20, 2018, 06:22:32 PM
Quote from: GigaWatt on July 20, 2018, 10:50:16 AM
I could probably have a look and see if I can get the mod working, since the author hasn't logged in since 2014, but I can't promise anything :S.
No worry, I understand perfectly - since these are free mods and all help are given voluntarily. I do thank you in advance first. :P