Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Auto Delete/Move Thread After X days Details »»
Auto Delete/Move Thread After X days
Version: 1.00, by HaMaDa4eVeR HaMaDa4eVeR is offline
Developer Last Online: Nov 2012 Show Printable Version Email this Page

Category: Administrative and Maintenance Tools - Version: 3.6.4 Rating:
Released: 02-16-2007 Last Update: Never Installs: 121
 
No support by the author.

What does this hack do ?
This is second version of Auto Delete/Move Hacks, this hack can delete the zero post threads that was created before X days in your specific forums or it can move the zero post threads to specific(Archive) through scheduled task, by defualt delete the zero post every ten days, sure you can change the period as you want,
this is where the Auto Delete After X Days comes in handy!

Features:
  • Turn On/Off system "All system".
  • Turn On/Off Move system.
  • Turn On/Off Delete system.
  • Specific forums "this hack will work on this forums only".
  • Specific forums " Archive Forums".
  • Protected Users.
  • Delete Type (soft/hard).
  • Created days.
  • NO Code Modifications needed!

Install instructions:

1- Upload the file to forum/includes/cron.
2- Import the Product XML file through your Admincp.
3- Enjoy.

NOTE:
Do not forget to review the hacks options in vBulletin options under "Auto Delete/Move After X Days " to set it as you want, the defualt setting are:-
- Soft delete for the threads that have zero replay and created before 30 days ago.
- protected user that have id 1 & 2.
- it will running every ten days.
- check the attachments.


that's all
Any questions, comments, suggestions, pleaes let me know

Enjoy!

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 02-19-2007, 03:49 PM
powerbook's Avatar
powerbook powerbook is offline
 
Join Date: Jul 2006
Posts: 132
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This can be very handy. I was looking for something that will move all threads that have been replied to in one forum to another... :up:

EDIT: I can't tell you how much this hack (with 2 changes to the cron query) solved a big headache I had for very long time... Thanks
Reply With Quote
  #13  
Old 02-19-2007, 06:34 PM
telc's Avatar
telc telc is offline
 
Join Date: Dec 2001
Posts: 128
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great add-on, could you add the option to and have it configurable on a per-forum basis?

Ignore Stickies [yes no]
Ignore Closed Threads [yes no]
Move threads where the last reply is atleast X days ago
Configurable on a Per-forum Basis ( so each forum can be configured different)

Smiliar to the options in the Prune and Threads section of Admincp.
Reply With Quote
  #14  
Old 04-05-2007, 07:54 AM
Forumi Shqiptar's Avatar
Forumi Shqiptar Forumi Shqiptar is offline
 
Join Date: Aug 2005
Posts: 135
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

can you add a feture to delete all the posts that has been Soft' deleted by the moderators???

Many thanks in advance (very nice mod anyway i clicked install)
Reply With Quote
  #15  
Old 04-11-2007, 10:44 PM
taxick taxick is offline
 
Join Date: Aug 2005
Location: Denmark
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I cant get it to work..

It dont create any on "Scheduled Tasks"...

And it dont move any Thread....

Can you help me?

And plz post the Scheduled Task info... So i can add it manuel.

Thx
Reply With Quote
  #16  
Old 04-20-2007, 03:34 PM
HaMaDa4eVeR's Avatar
HaMaDa4eVeR HaMaDa4eVeR is offline
 
Join Date: Jun 2004
Location: Sudan
Posts: 107
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
I cant get it to work..

It dont create any on "Scheduled Tasks"...

And it dont move any Thread....

Can you help me?

And plz post the Scheduled Task info... So i can add it manuel.

Thx
run this query in your forum database :
Code:
INSERT INTO " . TABLE_PREFIX . "cron (weekday,day,hour,minute,filename,loglevel,active,varname, volatile,product)) VALUES (-1, 10, 0, 'a:1:{i:0;i:0;}', './includes/cron/cronautodelete.php', 1, 'Auto Delete/Move Thread After X days')
make sure that you've uploaded the file cronautodelete.php in ./includes/cron/cronautodelete.php

and It should be working now...

thanks all for your suggestions,and It will be done soon
Reply With Quote
  #17  
Old 04-23-2007, 08:11 AM
littlematts littlematts is offline
 
Join Date: Jan 2007
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Dear HaMaDa4eVeR,

Thank a bunch for this beautiful mod i was always looking for. I will be lot greatful if you can help me on how to make this mod delete threads "after x days of inactivity". ie; the thread will be deleted after x days of no reply.

To be specific, our forum moderators send "junk" or "spam" to a forum named "thrash" and we need to make the "thrash bin forum" work with your script so as it will delete the threads in that "thrash forum" after X days a thread stays in thrash.

is it possible with a mod in this mod??

hopefully waiting for your reply

regards
Matthew
Reply With Quote
  #18  
Old 05-14-2007, 06:01 PM
HaMaDa4eVeR's Avatar
HaMaDa4eVeR HaMaDa4eVeR is offline
 
Join Date: Jun 2004
Location: Sudan
Posts: 107
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by littlematts View Post
Dear HaMaDa4eVeR,

Thank a bunch for this beautiful mod i was always looking for. I will be lot greatful if you can help me on how to make this mod delete threads "after x days of inactivity". ie; the thread will be deleted after x days of no reply.

To be specific, our forum moderators send "junk" or "spam" to a forum named "thrash" and we need to make the "thrash bin forum" work with your script so as it will delete the threads in that "thrash forum" after X days a thread stays in thrash.

is it possible with a mod in this mod??

hopefully waiting for your reply

regards
Matthew
O.K
I'm ready to help you..
but the support for installed members only
Reply With Quote
  #19  
Old 05-16-2007, 06:47 PM
littlematts littlematts is offline
 
Join Date: Jan 2007
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by HaMaDa4eVeR View Post
O.K
I'm ready to help you..
but the support for installed members only
Let me say sorry for the long break. I was in a hurry to change my work profile that made me lag to reply for your prompt help u offered.

I will be only happy to install the mod if it can be made compatible with the thread deletion rule mentioned.. only very happy to..

Pls do reply if you are keeping track mate.. I will be prompt for now on..

Thank you once agn and sorry for incon caused

regards
Matts
Reply With Quote
  #20  
Old 05-29-2007, 04:35 AM
cmwg cmwg is offline
 
Join Date: Apr 2006
Posts: 19
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I can?t seem to get the SQL Query to work...

This is the dump of the "cron" table:
Code:
CREATE TABLE `cron` (
  `cronid` int(10) unsigned NOT NULL auto_increment,
  `nextrun` int(10) unsigned NOT NULL default '0',
  `weekday` smallint(6) NOT NULL default '0',
  `day` smallint(6) NOT NULL default '0',
  `hour` smallint(6) NOT NULL default '0',
  `minute` varchar(100) NOT NULL default '',
  `filename` varchar(50) NOT NULL default '',
  `loglevel` smallint(6) NOT NULL default '0',
  `active` smallint(6) NOT NULL default '1',
  `varname` varchar(100) NOT NULL default '',
  `volatile` smallint(5) unsigned NOT NULL default '0',
  `product` varchar(25) NOT NULL default '',
  PRIMARY KEY  (`cronid`),
  UNIQUE KEY `varname` (`varname`),
  KEY `nextrun` (`nextrun`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Dumping data for table `cron`
--


/*!40000 ALTER TABLE `cron` DISABLE KEYS */;
LOCK TABLES `cron` WRITE;
INSERT INTO `cron` VALUES (1,1179093660,-1,-1,0,'a:1:{i:0;i:1;}','./includes/cron/birthday.php',1,1,'birthday',1,'vbulletin'),(2,1179014160,-1,-1,-1,'a:1:{i:0;i:56;}','./includes/cron/threadviews.php',0,1,'threadviews',1,'vbulletin'),(3,1179012300,-1,-1,-1,'a:1:{i:0;i:25;}','./includes/cron/promotion.php',1,1,'promotion',1,'vbulletin'),(4,1179093720,-1,-1,0,'a:1:{i:0;i:2;}','./includes/cron/digestdaily.php',1,1,'digestdaily',1,'vbulletin'),(5,1179095400,1,-1,0,'a:1:{i:0;i:30;}','./includes/cron/digestweekly.php',1,1,'digestweekly',1,'vbulletin'),(6,1179093720,-1,-1,0,'a:1:{i:0;i:2;}','./includes/cron/subscriptions.php',1,1,'subscriptions',1,'vbulletin'),(7,1179014700,-1,-1,-1,'a:1:{i:0;i:5;}','./includes/cron/cleanup.php',0,1,'cleanup',1,'vbulletin'),(8,1179011400,-1,-1,-1,'a:1:{i:0;i:10;}','./includes/cron/attachmentviews.php',0,1,'attachmentviews',1,'vbulletin'),(9,1179093780,-1,-1,0,'a:1:{i:0;i:3;}','./includes/cron/activate.php',1,1,'activate',1,'vbulletin'),(10,1179011700,-1,-1,-1,'a:1:{i:0;i:15;}','./includes/cron/removebans.php',1,1,'removebans',1,'vbulletin'),(11,1179012000,-1,-1,-1,'a:1:{i:0;i:20;}','./includes/cron/cleanup2.php',0,1,'cleanup2',1,'vbulletin'),(12,1179093600,-1,-1,0,'a:1:{i:0;i:0;}','./includes/cron/stats.php',0,1,'stats',1,'vbulletin'),(13,1179012300,-1,-1,-1,'a:2:{i:0;i:25;i:1;i:55;}','./includes/cron/reminder.php',0,1,'reminder',1,'vbulletin'),(14,1179094200,-1,-1,0,'a:1:{i:0;i:10;}','./includes/cron/dailycleanup.php',0,1,'dailycleanup',1,'vbulletin'),(15,1179012000,-1,-1,-1,'a:2:{i:0;i:20;i:1;i:50;}','./includes/cron/infractions.php',1,1,'infractions',1,'vbulletin'),(16,1179011400,-1,-1,-1,'a:1:{i:0;i:10;}','./includes/cron/ccbill.php',1,1,'ccbill',1,'vbulletin'),(17,1179011400,-1,-1,-1,'a:6:{i:0;i:0;i:1;i:10;i:2;i:20;i:3;i:30;i:4;i:40;i:5;i:50;}','./includes/cron/rssposter.php',1,1,'rssposter',1,'vbulletin'),(18,1179093900,-1,-1,0,'a:1:{i:0;i:5;}','./includes/cron/birthdaythread.php',1,1,'Automatic Birthday Thread',1,'vbulletin');

I just get the following error:
Quote:
An error occurred while attempting to execute your query. The following information was returned.
error number: 1064
error desc: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '" . TABLE_PREFIX . "cron (weekday,day,hour,minute,filename,loglevel,active, varna' at line 1
after editing the query to:
Code:
INSERT INTO cron VALUES (-1, 10, 0, 'a:1:{i:0;i:0;}', './includes/cron/cronautodelete.php', 1, 'Auto Delete/Move Thread After X days')
i then get the error:

Quote:
An error occurred while attempting to execute your query. The following information was returned.
error number: 1136
error desc: Column count doesn't match value count at row 1
what is wrong?
Reply With Quote
  #21  
Old 05-30-2007, 02:14 PM
louis_chypher's Avatar
louis_chypher louis_chypher is offline
 
Join Date: Mar 2006
Location: Boise, Idaho
Posts: 130
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

CREATE TABLE `cron` (

table prefix?

The table prefix I use is "vb_"

thus I use

CREATE TABLE `vb_cron` (

*shrug*




INSERT INTO cron
(field1,field2,field3,...)
VALUES
(-1, 10, 0, 'a:1:{i:0;i:0;}', './includes/cron/cronautodelete.php', 1, 'Auto Delete/Move Thread After X days')

see http://dev.mysql.com/doc/refman/5.0/en/insert.html for the proper syntax for the INSERT statement.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:07 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05338 seconds
  • Memory Usage 2,325KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (3)bbcode_code
  • (5)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete