Module: Recent Messages

Posted by Maurice Makaay 
Re: Module: Recent Messages
October 16, 2008 11:10AM
Using the Module "Recent Messages" 2.0.13, I ran into a problem right now. I had set up a new iCalamus forum (Polish) and have created some groups in the admin area.

Afterwards, the "Recent Messages" page created this error:
[code="php"]Warning: array_shift() [<a href='function.array-shift'>function.array-shift</a>]:
The argument should be an array in
[...]/phorum/mods/recent_messages/recent_messages.php
on line 231[/code]

The relevant part looks liks this:
[code="php"]
if (empty($folders[$folder_id])) {
array_shift($path);
if (empty($path)) $path = array($PHORUM['DATA']['LANG']['Forums']);
$folders[$folder_id]['path_name'] = join(" &#187; ", $path);
}
[/code]

I changed it into this:
[code="php"]
if (empty($folders[$folder_id]))
{
if (is_array($path)
array_shift($path);

if (empty($path))
$path = array($PHORUM['DATA']['LANG']['Forums']);

$folders[$folder_id]['path_name'] = join(" &#187; ", $path);
}
[/code]

Now it works fine here, but I have no idea if it was a Module bug or something else. Please check this and give me a note. Thank you.

Regards, Ulf Dunkel
Re: Module: Recent Messages
October 16, 2008 12:51PM
did you try to just rebuild your forum paths?


Thomas Seifert
Re: Module: Recent Messages
October 16, 2008 11:00PM
No, I didn't. I just set up a new forum instance (#12, Polish). Then I created some new groups in the admin area and linked some users to these groups. After that I checked the forum pages and saw the php warning.

Regards, Ulf Dunkel
Re: Module: Recent Messages
October 17, 2008 02:43AM
then please try this as it sounds like the path hasn't been built for this forum (if maurice doesn't have another idea directly about this forum) which you can see with the missing breadcrumbs.
your lang files for at least danish, italian and latvian are missing the home-entry, when you check the breadcrumbs again.
Oh, and upgrading could be a good idea too.


Thomas Seifert



Edited 1 time(s). Last edit at 10/17/2008 02:43AM by Thomas Seifert.
Re: Module: Recent Messages
October 17, 2008 04:09AM
Hi Thomas. I wonder what went wrong when I set up the new Polish forum instance, but rebuilding the Phorum paths seemed to help much as now even the Polish forum title is properly shown. I also added the 'Home' entries to all relevant files, thank you for pointing me to this.

Upgrading to what? I run 5.2.7 in all my sites.

Regards, Ulf Dunkel
Re: Module: Recent Messages
October 17, 2008 04:18AM
I think Thomas means an upgrade to 5.2.9a, the current stable version.


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: Recent Messages
October 17, 2008 04:32AM
Hi Maurice. Thank you. I usually don't use versions which are not shown by the "Maintenance: Check For New Version" stuff if you guys don't explicitely recommend to do so for several important reasons. I'm no early starter, rather Earl Grey lover. ;-)

Regards, Ulf Dunkel
Re: Module: Recent Messages
October 17, 2008 04:39AM
it is recommended but the new version check in 5.2.7 is broken and got fixed in 5.2.9

Addition by Maurice: see changeset 3506


Thomas Seifert



Edited 1 time(s). Last edit at 10/17/2008 04:53AM by Maurice Makaay.
Re: Module: Recent Messages
October 22, 2008 03:26AM
Hello,
I've installed this mod for my forum but I don't understand why messages that have been read are still in the list of news messages.

I've attached a screenshot of the problem.
We can see that the last messages have been read but are still in the list why ?

Thank you in advance.

mmakaay: removed the image from this message, to clean up the file listing at the top of the page a bit.

--------------------------------
Christophe, [www.notre-planete.info]



Edited 1 time(s). Last edit at 07/22/2009 10:58AM by Maurice Makaay.
Re: Module: Recent Messages
October 22, 2008 03:33AM
because its recent messages, so its listing the last posted messages and not only unread messages.


Thomas Seifert
Sorry, only registered users may post in this forum.

Click here to login