View Full Version : [release] Last Thread Titles on Forumhome (Cleaner)
filburt1
12-15-2002, 10:00 PM
Requires PAPI. See the instructions for details.
Author: filburt1
Description: Includes the title of the last thread along with the last poster and date/time on forumhome.
Screenshot: next post
Demo: none yet
An important note! The last title for a given forum will only update when you post a new thread (newthread.php). Editing, deleting, moving, etc. a thread will not change this cache.
To get around this, run a cron job that executes "report.php?updatethreadtitlecache=1" every 10 minutes or so. This script uses about 6 queries on top of the few needed to run report.php. Once that script is ran, every last thread title will be updated.
If you don't know what a cron job is, I don't suggest you try this mod unless you want to play around with the database manually.
filburt1
12-16-2002, 06:24 PM
Screenshot:
imported_Blindchild02
12-16-2002, 07:14 PM
hmm, dunno might make it look a bit cluttered, but nice nonethe less
Cypher720
12-16-2002, 09:42 PM
aw dude - EXCELLENT mod!
ive been wanting this for a LONG time!!
thanks man...10/10
-Cypher
filburt1
12-16-2002, 09:44 PM
Is it working for you?
Cypher720
12-16-2002, 09:55 PM
didnt try yet - i got lots of work. maybe later tonight ill install it o a test board...why...is there a problem?
filburt1
12-16-2002, 10:05 PM
No, I'm just getting the feeling that I forgot something from the instructions. It's also the first real test of PAPI :)
Tony G
12-16-2002, 10:34 PM
There are two of this you released right filbie? PAPI and normal?
filburt1
12-16-2002, 10:40 PM
Yes. The other one requires fewer queries but is incredibly cheap how it works and doesn't need PAPI.
Cypher720
12-16-2002, 10:41 PM
i havent used PAPI yet - ill test it later:)
aznhood
12-17-2002, 04:43 AM
It's not showing the title nor the link of the last post. It just showed the lastposter's username and time.
aznhood
12-17-2002, 04:51 AM
oh never mind, I got it. Thanks!
Tony G
12-17-2002, 05:19 AM
I'll test some of these PAPI mods out, I'm eager to see how it works.
imported_Crazy Mofo
12-17-2002, 10:27 AM
would it be possable too update it too when u new post is posted it shows the title of that thread?
filburt1
12-17-2002, 01:21 PM
Remember the only time an update happens is when a new thread is posted. Any other situation requires that you update via the cron job. You should also run the cron job right after installing the mod to set all of the last titles with their initial values.
imported_Crazy Mofo
12-17-2002, 03:17 PM
ok done that sorry i didnt read it :) anyways i set it 2 20 mins gonna see if it works ;)
imported_Crazy Mofo
12-17-2002, 03:19 PM
ok my user cp for the host has a online cron job is this the command only?
report.php?updatethreadtitlecache=1
?
imported_Crazy Mofo
12-17-2002, 03:22 PM
here also would i have too run the query again?
filburt1
12-17-2002, 05:29 PM
I think it's just php /path/to/vb/report.php?updatethreadtitlecache=1. I haven't tried it yet though because I can't change my live style until January 1 and my test board is only on Windows which doesn't include Cron.
imported_Blindchild02
12-18-2002, 06:52 PM
whats url for the non papi one?
filburt1
12-18-2002, 06:54 PM
<a href="http://www.vbulletintemplates.com/mods/showthread.php?s=&threadid=2316" target="_blank">http://www.vbulletintemplates.com/mo...&threadid=2316</a> but this one is much better.
filburt1
12-28-2002, 04:14 PM
Update: if you have PAPI 1.0.5, find:
else if (thisis("newthread") && actionis("postthread"))
{
updatethreadtitlecache(false, $_POST['forumid'], $_POST['subject']);
}
After it, add:
else if (thisis("newreply") && actionis("postreply"))
{
updatethreadtitlecache(false, $_POST['threadid']);
}
That will force the last post title to update after a reply to a thread.
Also an important note: for you to be able to cron the update all script, this mod must be in the default style set.
squawell
01-03-2003, 10:29 AM
never mind i fixed my problem..........
Bad Bunny
02-11-2003, 01:45 AM
So in what ways is this one better than the non papi release? I am just trying to figure this all out.
How many queries does this add?
filburt1
02-11-2003, 01:46 AM
It's been a whlie since I wrote this but one or so when replying and a few with the cron job. It's better this way than the non-PAPI one because it works in any browser and doesn't reply on crazy Javascript. Also I think the other one has security issues.
zfrank
04-06-2003, 08:29 AM
What must I change to work with subforums..
in forumsummary I canĀ“t see the title of thread, if there is a new topic in subforum...
any solution?
Breaker
04-06-2003, 08:04 PM
ooo error.
Fatal error: Call to undefined function: thisis() in /usr/local/psa/home/vhosts/alixd.co.uk/httpdocs/global.php(929) : eval()'d code on line 8
using PAPI 1.0.9
Breaker
04-12-2003, 01:18 PM
i'm still having these problems, and am yet to find out the problem, any1 got ne ideas to help me
imported_Digital Hybrid
06-04-2003, 06:26 PM
I must have dome something wrong since I don't get the threadtitle... perhaps I installed PAPI wrong?
I'm having the same problem that Digital Hybrid is having, any clues?
MGM out
mbowers
07-12-2003, 05:20 AM
The instructions say:
In phpinclude, find:
// ---------------------------------------------------------------
// ------------------------- End PAPI ----------------------------
// ---------------------------------------------------------------
But all I've got in phpinclude is the following:
include("./customscripts/papi.php");
// This code is PHP4 only:
// ob_start();
// require("yourheader.html");
// $header = ob_get_contents();
// ob_end_clean();
sonic3d
07-14-2003, 11:11 PM
nvm, fixed it
l8er
sonic
mbowers
07-15-2003, 01:33 AM
I've got PAPI installed (note first line of my phpinclude above), but maybe I installed it wrong? I thought I just had to add that include statement to phpinclude and drop papi.php into a customscripts folder...
Thanks,
Mbow
daFish
07-21-2003, 09:35 AM
I must have dome something wrong since I don't get the threadtitle... perhaps I installed PAPI wrong?
Same for me. :(
-Fish
Jean147
08-06-2003, 12:18 PM
same problem either. :(
Jean147
08-08-2003, 02:47 PM
No more suppoet???
dstruct2k
08-15-2003, 12:30 PM
The instructions say:
In phpinclude, find:
// ---------------------------------------------------------------
// ------------------------- End PAPI ----------------------------
// ---------------------------------------------------------------
But all I've got in phpinclude is the following:
include("./customscripts/papi.php");
// This code is PHP4 only:
// ob_start();
// require("yourheader.html");
// $header = ob_get_contents();
// ob_end_clean();
Just think of include("./customscripts/papi.php"); as the End PAPI section... It should work, so long as you add everything after include("./customscripts/papi.php"); and before // This code is PHP4 only:... Have fun!
Andrew111888
08-18-2003, 02:08 AM
I'm doing that, and still no title is appearing for me.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2024, vBulletin Solutions Inc.