collapse

* Simple Portal Archived Forum

This is an Archive Forum.

The content in this forum may be out-of-date or have been superseded by newer information, and links in forum pages to other sites may not work.
This forum contains archives for future reference.

Visit our thread at Simple Machines Forum for current support.

SMF 2.1 users: EhPortal is a ported version of Simple Portal specifically designed for the SMF 2.1 branch.
Please visit web-develop.ca to download EhPortal and for its support.

* User Info

 
 
Welcome, Guest. Please login or register.

* Who's Online

  • Dot Guests: 408
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.

* Shoutbox

Refresh History
  • Shoutbox is not for support!
  • {OCS}MasterSeal: Yup, Still adore SP
    April 21, 2019, 07:08:06 PM
  • {OCS}MasterSeal: STILL love SP :)
    November 24, 2018, 05:05:50 AM
  • ♦ Ninja ZX-10RR ♦: <3 aegersz
    September 13, 2018, 03:36:09 PM
  • aegersz: I STILL <3 LOVE SimplePortal
    September 13, 2018, 07:11:39 AM
  • aegersz: o LOVE you guys - Simple Portal rocks !
    May 09, 2018, 05:18:59 AM
  • Chen Zhen: our apologies for the site being down.. please read server issues topic
    March 22, 2018, 05:32:38 AM
  • {OCS}MasterSeal: LOL PLEASE forget I just posted that. I found the answer in my own dang post back in 2015. lol sorry!
    July 04, 2017, 10:47:55 PM
  • {OCS}MasterSeal: I know this SB isnt' for support, but I just have a general question. Who would I contact to find out where SP stores its block info? Is it DB driven or files? I searched the site but came up with nothing. probably my fault any insight is appreciated.
    July 04, 2017, 10:43:36 PM
  • ♦ Ninja ZX-10RR ♦: Excuse me but what does Simpleportal have to deal with that?
    February 05, 2017, 08:21:14 PM
  • WhiteEagle: of course IMHO that site appears to be dead :(
    February 04, 2017, 01:08:05 PM
  • WhiteEagle: If I can get that, then I'll use it for that site...
    February 04, 2017, 01:07:35 PM
  • WhiteEagle: decided to not use SMF for any projects, unless I can get a copy of the premium version of the fanfiction archive plugin
    February 04, 2017, 01:06:54 PM
  • expertdecisions: cloudflare
    January 28, 2017, 08:01:47 AM
  • aegersz: SM release 2.0.13 !
    January 12, 2017, 06:00:13 AM
  • raffo: Tks Emanuele, even if I didn't understand the fix :D
    November 07, 2016, 02:01:20 AM
  • emanuele: [link]
    November 01, 2016, 12:43:50 PM
  • emanuele: raffo: the English support board is a good place. ;)
    November 01, 2016, 12:43:38 PM
  • raffo: Where can I find the fix for the shoutbox?
    November 01, 2016, 05:06:09 AM
  • {OCS}MasterSeal: To the SP team, I make a point to come here and thank you as much as possible for your work.  so again, THANK YOU!
    October 28, 2016, 10:38:05 AM
  • emanuele: That's indeed funny, the limit is present only in the patch and not the full install.
    October 22, 2016, 06:14:58 PM

* Recent Posts

Adding Forums Button to Nav bar by jirapon
[August 01, 2019, 09:07:12 AM]


Re: Board Icons by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 04:03:41 PM]


MOVED: Czech translation???? by ♦ Ninja ZX-10RR ♦
[July 30, 2019, 03:04:51 PM]


Board Icons by jirapon
[July 30, 2019, 07:28:44 AM]


Re: Thankyou Simpleportal, by ♦ Ninja ZX-10RR ♦
[July 29, 2019, 09:41:29 AM]

If you're interested in helping other members with support requests, consider joining the Community Support Helpers group.

Author Topic: Is it possible to make Recent Posts/Topics a little less Recent?  (Read 13159 times)

0 Members and 2 Guests are viewing this topic.

Offline Dwev

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
I'm using SimplePortal 2.3.7 on SMF 2.0.15 and I'm very happy with the combination.

But there's is one big but: the Recent Posts/Topics block only shows things that really, really recent, and that doesn't work for all of the forums/boards. Because some are much 'slower' than others, so I can't use Recent Posts/Topics for this.

Is there a way to make Recent Posts/Topics a little less Recent?

By the way, this question has come up multiple times in the support thread for SimplePortal on the SMF forum, but has never been answered there, as far as I can see.

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #1 on: May 06, 2018, 11:56:03 AM »
Well, you can change the number of posts/topics to display? (It's among the settings of the block.)
Apart from that, I think the only reliable alternative is to have two different blocks.

Offline Dwev

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #2 on: May 08, 2018, 08:31:20 AM »
@ emanuele: I know that I can adjust the number of posts/topics to display.

But that doesn't help of the code behind it just deems the posts and topics too old and doesn't display them anymore because of that.

I don't understand how two different blocks would help, the code behind them is the same and they both wouldn't display anything.

I think my question is really about adapting some of the code used in this SimplePortal block, and I hope that the coders of SimplePortal are here to answer it (like I wrote before, the support thread on the SMF forum doesn't yield an answer to this problem).

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #3 on: May 08, 2018, 03:06:20 PM »

Simple Portal actually uses recent posts or recent topics from SSI.php.
The only allowance with the current coding is the total number of posts or topics to display in descending order from all selected boards.
Due to other mods or functions possibly using those same SSI.php functions it will be necessary to create specific functions for this purpose.

I can do that for you in the form of a plug-in so you do not have to do any editing/coding.
Perhaps it will be best to include 2 additional inputs to include oldest date to query and how many from each board.
This way the list will not be too lengthy in some circumstances.

Does that sound correct?
Am I understanding what you are requesting properly?


Offline Dwev

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #4 on: May 09, 2018, 12:55:14 PM »
@ Chen Zhen: thank you, very, very much for this offer!

To make sure that it's clear what the problem is: when I use the current option for Recent Posts/Topics in SimplePortal it works like a charm, but only of the boards that are included that have very often new posts.

But we would love to have some blocks for 'slow' boards as well, in one of those the latest posts were on the following dates:

7th of May 2018
14th of April 2018
17th of March 2018
17th of March 2018
1st of March 2018
23rd of April 2017
21st of April 2017
26th of October 2016

If I make a new Recent Posts/Topics block for this board it says that there isn't any recent to display, none at all. I would love to have the option to set the period that it should collects posts and topics from, so that it would display posts from the last months, half year of even a bit longer.

I'm sure more people would like this.
« Last Edit: May 10, 2018, 10:41:49 AM by Dwev »

Offline emanuele

  • Developer
  • *
  • Posts: 293
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #5 on: May 10, 2018, 07:12:51 AM »
Oh, okay, you meant in *that* sense.
I understood it was showing only few posts because the forum was too active and it was not showing enough.

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #6 on: May 10, 2018, 03:10:28 PM »
I added the function to one of my existing mods.
You can download it from here:
https://web-develop.ca/index.php?action=downloads;area=stable_simple_portal_plugins;file=26

Adjust the new options in your recent posts/topics block settings.
The mod also attempts to fix broken bbcode/html in posts it displays within board news.

Please let me know if that works as expected.

Offline Dwev

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #7 on: May 11, 2018, 02:53:56 AM »
Please let me know if that works as expected.

Yes it does, problem solved and I'm now a very happy camper!

Do I have your permission to post this in the SMF forum as well?
There were people there in the past that were looking for the same solution...

By the way: in the package-info.xml it says "install for="2.0 - 2.0.98", were it normally says "install for="2.0 - 2.0.99".
Is that a typo, or an inside joke?

Offline Dwev

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #8 on: May 11, 2018, 04:17:31 AM »
And one more question (hope I'm not getting too greedy here):

Would it also be possible to exclude topics that are locked from the list of Recent Posts/Topics?

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #9 on: May 11, 2018, 08:59:01 AM »
Quote
Do I have your permission to post this in the SMF forum as well?

You can post the link to the download page on my forum but not the plug-in itself.



Quote
Would it also be possible to exclude topics that are locked from the list of Recent Posts/Topics?

It uses topics from the boards you opt in the block settings.
All topics that are visible to the member will be listed.
To have it use some sort of specific topic selection would just be too vast of a list on the admin page in most circumstances.
To convey specific information such as you suggest is what something like articles is for.
 
I will be making another update to the plug-in later today.. it will be version 1.21 when it is ready and available from the same download page.
I overlooked something regarding total number of topics/posts that has to be adjusted.


Quote
By the way: in the package-info.xml it says "install for="2.0 - 2.0.98", were it normally says "install for="2.0 - 2.0.99".

There will never be SMF 2.0.99 for that branch.
I set that up like that on purpose in all my mods/plug-ins due to SMF 2.1 beta/RC versions (2.0.99 - 2.1.98).
It's a branch catch-all that works quite well. SMF devs do version increments in such a way that it will never reach that .99 version number.
« Last Edit: May 11, 2018, 09:10:37 AM by Chen Zhen »

Offline Dwev

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #10 on: May 12, 2018, 06:09:17 AM »
@ Chen Zhen: thank you for al the great work and answers, I just installed version 1.2.1 and it installed without a problem 9everything still working as it should).

If I post anything on the SMF board I will use the following link: https://web-develop.ca/index.php?action=downloads;area=stable_simple_portal_plugins

Is that the right one?

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #11 on: May 12, 2018, 09:51:19 AM »

That's the link to all my Simple Portal plug-ins.
You can use that one or be specific to the plug-in you are posting about.
This plug-in is:
https://web-develop.ca/index.php?action=downloads;area=stable_simple_portal_plugins;file=26

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #12 on: May 15, 2018, 01:52:53 PM »

Try version 1.22 from the link in the last post.
Let me know if what you reported persists.

Offline Dwev

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #13 on: May 16, 2018, 03:00:56 AM »
It turns our 1.2.2 removed all of the text showing in the blocks with news on the front page.

So I'm back to version 1.2.1 and at the moment accents aren't shown right again, and hoping that there's a way to fix this.
« Last Edit: May 16, 2018, 06:46:06 AM by Dwev »

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #14 on: May 16, 2018, 09:03:21 AM »

That is strange as I did test it locally. Was there errors in the log? Perhaps your OS is void of multibyte support?

I will fix that mod but for now to help you out I made a mod with only what you requested.
Uninstall Truncate 1.2.1 and install the attachment in its stead.

Offline Dwev

  • Semi Newbie
  • *
  • Posts: 8
  • SMF Version: 2.0.15
  • SP Version: 2.3.7
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #15 on: May 16, 2018, 11:10:33 AM »
Uninstalled Truncate 1.2.1 and installed SP_Post-Topic-Age_v1.0x and all is well.

So both the 'slow' boards still show fine on the front page, and all of the accents are showing again as they should.

Thanks you very, very much for all of this, including making an extra plugin, I feel privileged!

About multibyte support, I asked one of the admins about this and his answer was: "Yup, (php7.1-mbstring is already the newest version)".

Offline Chen Zhen

  • The Underdog
  • Operations Manager
  • *
  • Posts: 1350
  • Gender: Male
  • Kinesis
    • WebDev
  • SMF Version: 2.1
  • EhPortal Version: 1.22
Re: Is it possible to make Recent Posts/Topics a little less Recent?
« Reply #16 on: May 16, 2018, 01:18:08 PM »
Glad you got everything sorted.

I believe it had something to do with the DOM filter I use for truncating posts/topics.
The recent post/topic alterations have been removed from the truncate plug-in (v1.23).
In my download section there now exists a new SP plug-in for recent posts/topics which I just gave you.

If you ever find yourself in need of the truncate plug-in please don't hesitate to download & try it again.
It has been adjusted and tested with various language characters which seem to work in my local environment.

If you don't mind me asking... What language is your forum/database set to?
Can you provide an example of a post that was giving the issue perhaps in a PM so that I can test the specific characters?
« Last Edit: May 16, 2018, 01:34:39 PM by Chen Zhen »