[ABD] Recent Posts - Last Active Post Show phpBB3 Mod

Any abandoned MODs will be moved to this forum.

WARNING: MODs in this forum are not currently being supported or maintained by the original MOD author. Proceed at your own risk.
Forum rules
IMPORTANT: MOD Development Forum rules

WARNING: MODs in this forum are not currently being supported nor updated by the original MOD author. Proceed at your own risk.
TimeZone
Registered User
Posts: 52
Joined: Mon Jul 23, 2007 8:35 pm

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by TimeZone »

It's strange because this variables not exist more. I depure the code and eliminate them. Refresh your site or clean the temporary files. If you can enter to the ACP clan the cache, and test again!

Here are the old version:
http://www.foronokia.com.ar/FNKserver/reduce_mod.rar
http://www.foronokia.com.ar/FNKserver/L ... _Index.rar
TZ!
User avatar
WhiteWolfSix
Registered User
Posts: 258
Joined: Sun May 15, 2005 5:43 am

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by WhiteWolfSix »

I installed your latest MOD only (no previous ones) that is in folder named NewMod and I got these errors.


Edit: You should check the last_post.php file. I found those undefined variables there.
Edit2: OK, I found you have updated download link in first post. It is OK for now after reinstalling the last_post.php file. :mrgreen:
Image
WhiteWolfSix (WW6)
User avatar
WhiteWolfSix
Registered User
Posts: 258
Joined: Sun May 15, 2005 5:43 am

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by WhiteWolfSix »

OK, I have another question. :mrgreen: Why this icon Image is showing after post is read? :roll:
Image
WhiteWolfSix (WW6)
stokerpiller
Registered User
Posts: 1934
Joined: Wed Feb 28, 2007 8:06 pm

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by stokerpiller »

WhiteWolfSix wrote:OK, I have another question. :mrgreen: Why this icon Image is showing after post is read? :roll:
Yes, there is no errors in the newest download.
That icon is standard. You can choose to use a different be editing the the html files.
I use topic_read.gif
This Mod isn't about showing which post is read, only showing newest posts.


Timezone -> The newest download works perfect, with no Debug errors. Username colors works fine 8-)
This is cool.
You have done a great job. Keep it up.
I hope You get this MOD validated.
I will keep up testing if needed. But I am happy with the newest version :mrgreen:
I am done with phpBB
saaiberke
Registered User
Posts: 1126
Joined: Wed Jul 20, 2005 8:13 am
Location: Gent/Belgium

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by saaiberke »

Timezone,

Nice mod, although I found a little problem in /includes/last_post.php. You hardcoded the tables prefix, so for people that don't use the standard phpBB_ prefix, the mod won't work.

I have the phpBB3_ prefix in my board and it didn't work. I had to edit the last_post.php by hand to make it work.

Maybe it would be better to use the config variables via editing the constants.php for the prefix or at least mention something in the instructions files so users know they have to edit it manually.

Grtz and thanks for a great mod.

Nic
TimeZone
Registered User
Posts: 52
Joined: Mon Jul 23, 2007 8:35 pm

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by TimeZone »

saaiberke wrote:Timezone,

Nice mod, although I found a little problem in /includes/last_post.php. You hardcoded the tables prefix, so for people that don't use the standard phpBB_ prefix, the mod won't work.

I have the phpBB3_ prefix in my board and it didn't work. I had to edit the last_post.php by hand to make it work.

Maybe it would be better to use the config variables via editing the constants.php for the prefix or at least mention something in the instructions files so users know they have to edit it manually.

Grtz and thanks for a great mod.

Nic
This mod is designed to work for the phpBB original using the standard code to program for this. The phpBB3 portal is using propietary includes, and maybe do the errors. But this mode must to work perfect in phpBB3 board, I review the variables in the original phpBB code and this are correct. Can you say my which variables are in problem?.

Sorry for my english, I think that is so bad jejejeje!

TimeZone
saaiberke
Registered User
Posts: 1126
Joined: Wed Jul 20, 2005 8:13 am
Location: Gent/Belgium

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by saaiberke »

No problem, my English isn't perfect either :)

What I mean is:

in /includes/last_post.php you use:

Code: Select all

    $sql = "SELECT topic_title, phpbb_topics.forum_id, topic_id, topic_time, topic_type, topic_status, poll_start, topic_last_post_id, topic_poster, topic_last_poster_id, topic_first_poster_colour, topic_last_poster_colour, topic_first_poster_name, topic_last_poster_name, topic_last_post_time, topic_last_post_subject, forum_name, topic_views, topic_replies, icon_id
       FROM " . TOPICS_TABLE . " LEFT JOIN phpbb_forums ON phpbb_topics.forum_id = phpbb_forums.forum_id
       LEFT JOIN phpbb_icons ON phpbb_topics.icon_id = phpbb_icons.icons_id
       WHERE topic_status <> 2
          AND topic_approved = 1
       ORDER BY topic_last_post_time DESC";
Here you are supposed to have the standard phpbb_ prefix for your database tables. But many people have another prefix (they choose another one at the boards installation).

For example:

I use phpBB3_ as a tables prefix so your query in last_post.php will give me a sql error because I don't have tables starting with phpBB_.

So I have to edit the file like this:

Code: Select all

    $sql = "SELECT topic_title, phpbb3_topics.forum_id, topic_id, topic_time, topic_type, topic_status, poll_start, topic_last_post_id, topic_poster, topic_last_poster_id, topic_first_poster_colour, topic_last_poster_colour, topic_first_poster_name, topic_last_poster_name, topic_last_post_time, topic_last_post_subject, forum_name, topic_views, topic_replies, icon_id
       FROM " . TOPICS_TABLE . " LEFT JOIN phpbb3_forums ON phpbb3_topics.forum_id = phpbb3_forums.forum_id
       LEFT JOIN phpbb3_icons ON phpbb3_topics.icon_id = phpbb3_icons.icons_id
       WHERE topic_status <> 2
          AND topic_approved = 1
       ORDER BY topic_last_post_time DESC";
Now in includes/constants.php you have:

Code: Select all

define('FORUMS_TABLE',				$table_prefix . 'forums');
So in the sql you can use ' . FORUMS_TABLE . ' ==> no matter which prefix the user is using, it will always be the corect one because it is already defined in /includes/constants.php via the config.php where it says:

Code: Select all

$table_prefix = 'phpbb3_';
or

Code: Select all

$table_prefix = 'phpbb_';
or

Code: Select all

$table_prefix = 'myforum_';
You see what I mean?

Changing your last_post.php with the defined tables will make your mod more universal for all databases regardless what prefix they use. ;)

Greetings,

Nic
TimeZone
Registered User
Posts: 52
Joined: Mon Jul 23, 2007 8:35 pm

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by TimeZone »

Yes you have reason, I don't see this error, thank you for advice me about this! I correct the mod inmediately!

Edit: I correct the problem, now you shuold put the file normally without modify anything and should be work very well!!!

The link is in the first post, I only correct the link! If you have any problem contact me!

TZ!
t0mcat
Registered User
Posts: 9
Joined: Tue Jan 11, 2005 1:50 pm

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by t0mcat »

nice mod!

by the way the language strings added are redundant, most of them are already present in the default language files ;)

...and i've got a feature request: i would like if the icons could change whenever the user reads the posts...

i'll stay tuned!
TimeZone
Registered User
Posts: 52
Joined: Mon Jul 23, 2007 8:35 pm

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by TimeZone »

t0mcat wrote:nice mod!

i've got a feature request anyway: i would like if the icons could change whenever the user reads the posts...

i'll stay tuned!
Well, in the next RC I promise that the images will change when the user read the post. I'm work in this modification. But I'm centered in the ACP for the mod!.

Sorry for my english!!!

TimeZone
User avatar
WhiteWolfSix
Registered User
Posts: 258
Joined: Sun May 15, 2005 5:43 am

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by WhiteWolfSix »

TZ: Nice job! I like your MOD. I suggest you to add into first post of this topic few more words into this part:
TimeZone wrote:The new version is set to show 10 posts, this can be changed modifying this line:
Find:

Code: Select all

$result = $db->sql_query_limit($sql, 10);
My recommendation is:
The new version is set to show 10 posts, this can be changed modifying this line in includes/last_post.php:
Image
WhiteWolfSix (WW6)
TimeZone
Registered User
Posts: 52
Joined: Mon Jul 23, 2007 8:35 pm

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by TimeZone »

WhiteWolfSix wrote:TZ: Nice job! I like your MOD. I suggest you to add into first post of this topic few more words into this part:
TimeZone wrote:The new version is set to show 10 posts, this can be changed modifying this line:
Find:

Code: Select all

$result = $db->sql_query_limit($sql, 10);
My recommendation is:
The new version is set to show 10 posts, this can be changed modifying this line in includes/last_post.php:
I think that in the next version of the mod it's will not neccesary to modify by code. The next version will have a ACP mod, that will allow to you modify the number of showing post, the position of the mod in the index (not confirmed), a on/off option.

I want to finish this mod completely in the last week, but I travel, and I believe that be complicated to me. For this reason I finish the more important part of the mod.

TimeZone
_joschi_
Registered User
Posts: 20
Joined: Sat Jan 20, 2007 12:36 am

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by _joschi_ »

Hi @ll,

if any1 can tell me how i can put this fine Mod in a new blanc Page- as portal.php or start.php

Thx
TimeZone
Registered User
Posts: 52
Joined: Mon Jul 23, 2007 8:35 pm

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by TimeZone »

_joschi_ wrote:Hi @ll,

if any1 can tell me how i can put this fine Mod in a new blanc Page- as portal.php or start.php

Thx
You must include this line:

Code: Select all

include($phpbb_root_path . 'includes/last_post.'.$phpEx);
At the last of the archive, it's same if you include this file in the inde.php.

And after you must include this lines:

Code: Select all

<!-- IF S_USER_LOGGED_IN -->
<!-- INCLUDE viewlast_post.html -->
<!-- ENDIF -->
In the part of the module that you want to show the mod.

Anything you can question me!

TimeZone
_joschi_
Registered User
Posts: 20
Joined: Sat Jan 20, 2007 12:36 am

Re: [RC1] Recent Posts - Last Active Post Show phpBB3 Mod

Post by _joschi_ »

ok i have test it.......... but my will lokks not so good as on your side!!??

i have this one
Image
but i like to have this one!
Image

whats wrong?? :roll:

Thx

Return to “[3.0.x] Abandoned MODs”