Previous Thread
Next Thread
Print Thread
Rate Thread
#232135 01/07/2003 12:01 AM
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
This script will allow you to correct your thread and post counts if they are off. Thanks goes to Dave_L and Gardener for helping keep this updated since I first released it.

This should work for 6.2 as well as 6.1 and 6.0

Download, read, install, use.
Attachments
63918-checkpostcount.6.2.zip (0 Bytes, 84 downloads)

Sponsored Links
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Go Dave!

Joined: Dec 2000
Posts: 1,471
Addict
Addict
Offline
Joined: Dec 2000
Posts: 1,471
Thx, Dave. I use it regularly.

Maybe it would be even better to find the reason, why the count get's wrong, but that should be much more time intensive that running your hack.

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
Would it make sense to augment this hack to fix the Last Post column data on the main index page, or would it be better to do that as a separate hack?

Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
I'll have to look at things to see what it would take to clean that up. I forget but I think we covered why this was happening once before, didn't we?

Sponsored Links
Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I've recently noticed that the Last Post info isn't getting updated properly when I move the most recent thread to another forum. I know that's probably a bug, but it would be useful to be able to update that column whenever it gets out of synch.

Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
I'll get this changed to update that as well then.

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
Kewl

You probably don't need this, but here's a snippet from one of my import scripts for updating this info. It would have to changed a bit, but the general processing should be the same.

Code
// Get Bo_LastNumber, Bo_Posterid, Bo_Last, Bo_lastMain from latest post in forum<br />list($bo_lastnumber, $bo_posterid, $bo_last, $bo_lastmain) = array(0, 0, 0, 0);<br />if ($bo_total > 0) {<br />   $result = do_query("<br />      SELECT   B_Number, B_Posterid, B_Posted, B_Main<br />      FROM     tmp_posts<br />      WHERE    B_Board = '$keyword'<br />      ORDER BY B_Posted DESC<br />      LIMIT    1<br />   ");<br />   list($bo_lastnumber, $bo_posterid, $bo_last, $bo_lastmain) = mysql_fetch_row($result);<br />   mysql_free_result($result);<br />   if (!$bo_lastnumber) {<br />      ubbimport_log("Warning: board $keyword, unable to determine Bo_LastNumber\n");<br />   }<br />   if (!$bo_posterid) {<br />      ubbimport_log("Warning: board $keyword, unable to determine Bo_Posterid\n");<br />   }<br />   if (!$bo_last) {<br />      ubbimport_log("Warning: board $keyword, unable to determine Bo_Last\n");<br />   }<br />   if (!$bo_lastmain) {<br />      ubbimport_log("Warning: board $keyword, unable to determine Bo_lastMain\n");<br />   }<br />}

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
This has been tested and true. Moved to finished mods.


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,157
Joined: July 2001
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)