php forum
php mysql forum
php mysql smarty
 
Topic Options
#238593 - 03/01/03 10:51 PM Deleted topics automatically go into forum instead
smilesforu Offline
Junior Member

Registered: 01/31/02
Posts: 676
I have a mod that is trigger happy on the delete button... of course once its gone I can't recover it. I would like to be able to have deleted posts go to a separate forum that can be deleted later if I wish. This may have been suggested previously or exist? If so I would like to add it to the controls of my site.

Top
Sponsored Links
Sponsor
      

Top  
#238594 - 03/02/03 02:11 AM Re: Deleted topics automatically go into forum instead [Re: Kelly]
RandyJG Offline
Junior Member

Registered: 03/11/03
Posts: 231
Loc: Canada
This is what I came up with for 6.0.1 that worked, and appears to work on a 6.2 test board. I would use this code at your own risk.<br /><br />"DeletedThreads" is the keyword for the forum that contains deleted threads. moderators need moderator rights to this forum in order for this to work.<br /><br />This moves them without a confirmation step.<br /><br />I put this in the editpost_manage.tmpl which would be displayed to only admin/mods.<br /><br />To move a post and replies:<br /><br /><FORM METHOD=POST action ="{$config['phpurl']}/admin/domovepost.php"><br /><INPUT TYPE=HIDDEN NAME=Cat VALUE="$Cat"><br /><INPUT TYPE=HIDDEN NAME=page VALUE="$page"><br /><INPUT TYPE=HIDDEN NAME=view VALUE="$view"><br /><INPUT TYPE=HIDDEN NAME=sb VALUE="$sb"><br /><input type=hidden name=o value="$o"><br /><input type=hidden name="Keyword" value="DeletedThreads"> <br /><INPUT TYPE=HIDDEN NAME="oldboard" value="$board"><br /><input type=hidden name="number" value="$Number"><br /><input type=submit value="*Delete Post & Replies" class="buttons"><br /></form> <br /><br />To move a thread/topic:<br /><br /><FORM METHOD = POST action ="{$config['phpurl']}/admin/domovethreads.php"><br /><INPUT TYPE=HIDDEN NAME=Cat VALUE="$Cat"><br /><INPUT TYPE=HIDDEN NAME=page VALUE="$page"><br /><INPUT TYPE=HIDDEN NAME=view VALUE="$view"><br /><INPUT TYPE=HIDDEN NAME=sb VALUE="$sb"><br /><input type=hidden name=o value="$o"><br /><input type=HIDDEN name="Keyword" value="DeletedThreads"> <br /><INPUT TYPE=HIDDEN NAME="oldboard" value="$Board"><br /><input type=hidden name="number" value="$Main"><br /><input type=submit value="*Delete Thread" class="buttons"><br /></FORM><br /><br />You could then hide the real delete buttons if you wanted.

Top
#238595 - 03/02/03 03:45 AM Re: Deleted topics automatically go into forum instead [Re: romka]
smilesforu Offline
Junior Member

Registered: 01/31/02
Posts: 676
Works so far... I like the idea of hiding the buttons and replacing them with these. But of course I would also like to keep the delete buttons for clean up reasons later. Hopefully he will use these instead of the real ones modified them with his name so he can see them...lol.<br /><br />Thanks for the help..

Top
#238596 - 04/09/03 05:56 AM Re: Deleted topics automatically go into forum instead (FIX) [Re: Kelly]
RandyJG Offline
Junior Member

Registered: 03/11/03
Posts: 231
Loc: Canada
I just discovered a bug in this that comes from a typo.<br /><br />In the code for move a post and replies I have:<br /><INPUT TYPE=HIDDEN NAME="oldboard" value="$board"><br /><br />This should be:<br /><INPUT TYPE=HIDDEN NAME="oldboard" value="$Board"><br /><br />The domovepost.php doesn't check that the value is given. So when it goes to update the post total and last post in the forum it doesn't update anything because the old board value is "" and won't be found.<br /><br />I came across this problem when adding this to domovepost to track the forum a post is being moved from:<br /><br /> admin_log("MOVEPOST", $oldboard."->".$Keyword." ".$moved);<br /><br />Some moves (as a result to using the delete/move button) wouldnt' have a oldboard value.

Top
#238597 - 04/09/03 02:52 PM Re: Deleted topics automatically go into forum instead (FIX) [Re: romka]
smilesforu Offline
Junior Member

Registered: 01/31/02
Posts: 676
Thanks for spotting that. I was having incorrect post totals and had no idea where it was coming from.

Top

Shout Box

Latest Posts
Web 2.0 Design
by fifalove
04/14/14 08:42 AM
Facelift for UBB Threads 6.5
by fifalove
04/14/14 08:41 AM
[7.5.7] Stop Forum Spam - Login Detection
by GeoffM1968
03/28/14 02:34 PM
(Views)Popular Topics
Known public proxy servers 2209001
Slash UBB 1284543
Integrated Index Page (IIP) 5.3.1 812510
Q & A 720161
Finished-[6.5.2] Games Arcade Deluxe v1.9 658409
[6.0x] Who's Online 4.0.0 [Finished] 596193
Integrated Index Page (IIP) 5.1.1 528550
TLD Bv2.1 Released - Threads Links Directory 503208
Finished-[6.5.1] Integrated Index Page (IIP) 6.5 436591
[6.3.x] [beta] Hit Hack 2.0 283857
Featured Member
Registered: 01/10/00
Posts: 5434
Forum Stats
13693 Members
60 Forums
37219 Topics
295895 Posts

Max Online: 1000 @ 12/18/13 04:32 AM

 

 

 
fusionbb message board php hacks