MyBB Community Forums

Full Version: Thread Count Help 1.4.3
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
I was hoping that i could get this plugin update to 1.4.3
http://community.mybboard.net/thread-26034.html

Yumi was very kind to make this for me and others that used it. I love it!
It almost works with 1.4.3, just does not display the thread numbers even after the recount of user's threads.

This is something i need really bad on my board.
My board relies on user's thread count more then posts count. My members take more pride in their thread count.
As you know, there is not even a way to see an actual thread number anywhere on the board for a user.

This is something i think should be in mybb by default.
Why would you have one and not the other? They are 2 different things.
In our case, separate threads numbers being more important.

If someone could look through this great plugin and see whats needed to update it, My board would be very grateful. My guess is it wont need much change.. i hope.
I have sent Yumi a message about this, but he said he does not have time anymore to do these things.

Would be a shame to see this plugin not apart of mybb's future.

This is the last thing i need, and my board is complete as it was when we ran 1.2.

Thanks

*Hi Matt Wink
Do you have the original numtopics.php file Yumi gave you?? When I go to download it here, I get errors everywhere.

I can do it if you could attach that file here...

Smile
BIG thanks Tom.. very kind of you. Here is the file and needed info

### In /inc/class_moderation.php, FIND: ###

    function delete_thread($tid)
    {
        global $db, $cache, $plugins; 

### REPLACE WITH ###

    function delete_thread($tid)
    {
        global $db, $cache, $plugins, $thread; 


After activating, you must do a recount of user's threads.
Go to Admin CP: Maintenance / Recount & Rebuild / Recount User Thread Counts

Big Grin
I'll work through this when I have a moment tomorrow... on my netbook at the minute so can't do any work...

Sad
Thats ok Tom.. i am just grateful you are doing it for us.

Thank you... i will wait as long as it takes Smile
I'll also use this when it's done Smile
Instructions:
  • Upload the files (./inc/plugins/numtopics.php and ./inc/tasks/usertopics.php)
  • Go to your Plugins page in the ACP and activate the addon

Hopefully that will work. There is no need to recount/rebuild anything as it should do it automatically. Instead of a recount, I added a task (it's easier and quicker for me to do it as a task!), so if you ever need to recount the threads made then just click on the clock in the task manager. The only problem is it might take a little while if you have a lot of members/threads - I've tried to keep the coding down to a minimum though...

Let me know if there are any problems. I've tested this on two 1.4 boards so fingers crossed... Shy

Credit goes to Yumi of course for the original plugin
Thanks again Tom Smile

Just trying to get it to work.
Seams most users topic count has not updated yet... still 0.
I clicked on the clock beside the task you made.. and the task is enabled.
[Image: iclnyp.jpg]

That only runs for about 2 sec.. does nothing. We have about 40000 topics.. so i know it's not doing it that fast.

I also ran the Rebuild Thread Counters just in case, did not help.

Any ideas?
Warning [2] mysql_fetch_array(): supplied argument is not a valid MySQL result resource - Line: 59 - File: C:\wamp\www\forums\inc\plugins\numtopics.php PHP 5.2.6 (WINNT)
File 	Line 	Function
[PHP] 	  	errorHandler->error
C:\wamp\www\forums\inc\plugins\numtopics.php 	59 	mysql_fetch_array
C:\wamp\www\forums\inc\plugins\numtopics.php 	67 	countThread
[PHP] 	  	numtopics_activate
C:\wamp\www\forums\admin\modules\config\plugins.php 	200 	call_user_func
C:\wamp\www\forums\admin\index.php 	387 	require
A horrible death...

Like the ending... Toungue

Goes back to saying Activate, clicking it says the table already exists, and there's no task.

Sad
Hmm, well.. the plugin activates fine for me.. no errors.
It just does not update the topic count on everyone.. on a few users it has.
Members that have made new topics since i activated it have a count, but only the new count from the new topic they just made.
Pages: 1 2 3