PDA

View Full Version : Close Threads After X Posts


damicatz
12-25-2001, 10:00 PM
Requested At : https://vborg.vbsupport.ru/showthread.php?s=&threadid=33500

This hack closes threads after a certain amount of posts. You can specify a post limit by forum and you can disable it in certain forums as well.

TheComputerGuy
12-26-2001, 01:52 AM
Nice Hack...very good idea..

bira
12-26-2001, 09:41 AM
You added an extra query.

I showed you in the request thread how to use the exist UPDATE query in newreply.

Lesane
12-26-2001, 11:39 AM
Great. Thanks.

damicatz
12-26-2001, 02:21 PM
[QUOTE]Originally posted by bira
You added an extra query.

I showed you in the request thread how to use the exist UPDATE query in newreply.

Lesane
12-27-2001, 02:11 PM
I found one error in your instructions:

Replace it with:
//Begin Close Threads Hack
$DB_site->query("INSERT INTO forum
(forumid,styleid,title,description,active,displayo rder,parentid,
parentlist,allowposting,cancontainthreads,daysprun e,newpostemail,newthreademail,
moderatenew,allowhtml,allowbbcode,allowimages,allo wsmilies,allowicons,
styleoverride,allowratings,countposts,moderateatta ch,AGREEMENT,CLOSETHREADS)
VALUES
(NULL,'$styleset','".addslashes($title)."','".addslashes($description)."','$isactive','$displayorder','$parentid',
'','$allowposting','$cancontainthreads','$daysprun e','".addslashes($newpostemail)."','".addslashes($newthreademail)."',
'$moderatenew','$aallowhtmlcode','$aallowbbcode',' $aallowimgcode','$aallowsmilies','$aallowicons',
'$styleoverride','$allowratings','$countposts','$m oderateattach','$closethreads')");
//End Close Threads Hack

You are adding after moderateattach this: AGREEMENT,CLOSETHREADS

AGREEMENT??? ;)

damicatz
12-27-2001, 11:41 PM
Odd,

I took that out (I use the same template for all my hacks)

*Hits Notepad*

grumpy
01-01-2002, 05:19 PM
A friend installed this hack and he said that while it did close the threads at the right time, it didn't use the 'close' button or any other indication that the thread was locked. It just wouldnt allow more posts. Is this a known issue with this hack or was there just a problem with my friend's install?

damicatz
01-01-2002, 06:46 PM
When I tested it on my board the threads were marked as closed so it might be a problem with your friends install. What version of vBulletin is he using?

TECK
06-10-2002, 12:36 AM
this hack will make your users to spam your forums. if they cant post, they will start a new thread in response to it. more work for you and your mods.