Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases

Reply
 
Thread Tools
Auto move threads to archive forum after x days Details »»
Auto move threads to archive forum after x days
Version: 1.00, by trafix trafix is offline
Developer Last Online: Jul 2008 Show Printable Version Email this Page

Version: 3.0.5 Rating:
Released: 01-20-2005 Last Update: 01-20-2005 Installs: 15
 
No support by the author.

Requested by Floris

This is another simple script based on the Close thread after 30 days .... BUT ...

This one will auto move all threads to an archive forum where the last post is 365 days or older

There is 2 variables for you to edit
1)
Defult is set to "1"
$newforum = the forum number that these threads are to be moved to

2)
Defult is set to 365
this means that threads that havnt been replied to in the last 365 days will be moved to the nominated archive forum
you can change 365 to whatever days you like

Trafix

Please click Install

Update
Found an error in the code please download new zip and replace the file on your forum

Added file ...

This file will move threads from a specific forum to another spacific forum, edit as instructed

Show Your Support

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

Comments
  #52  
Old 05-24-2005, 08:56 PM
Kruppa Kruppa is offline
 
Join Date: Apr 2003
Location: Canada
Posts: 41
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No problem!

I'm not sure how you do this loop thing but if you could show me how to get rid of this monster of a script it might solve all my problems.

Are sure you I can do it in my situation? Each section I'm moving threads from has its own dead threads section. That's why I thought I had to list them all.

Btw, it worked, only there was another mistake like you pointed out a little lower. Works now!
Reply With Quote
  #53  
Old 05-25-2005, 05:34 PM
KevinL KevinL is offline
 
Join Date: Apr 2005
Posts: 1,287
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by KevinL
This is almost what I have looking for!

Is it possible for this to move a thread once some one posts in it?

Like..a thread is started in one forum (news forum) and once someone replies it then moves to a discussion forum so others can reply?
Im guessing no one knows how to do this then with this? :disappointed:
Reply With Quote
  #54  
Old 05-30-2005, 02:09 AM
Rukas Rukas is offline
 
Join Date: Aug 2004
Posts: 162
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is there a way to make this work so that after 24 hours of a thread being posted it is moved, regardless of when the last post in the thread was. So basically it only works off when the thread was started, not replied to, and moves aver 24 hours (I assume setting days to 1 would work ).
Reply With Quote
  #55  
Old 06-10-2005, 10:26 PM
HeloHi's Avatar
HeloHi HeloHi is offline
 
Join Date: Feb 2005
Posts: 42
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How do you make this move only threads with no replies?
Reply With Quote
  #56  
Old 06-11-2005, 10:59 AM
lifesbattles lifesbattles is offline
 
Join Date: Apr 2005
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by trafix
ahhh ... ooops

should be
PHP Code:
$DB_site->query(
UPDATE " 
TABLE_PREFIX "thread 
SET forumid = 
$newforum 
Where lastpost <= 
$movedate 
AND forumid != 
$newforum 
OR sticky != 1 
"
); 
ugh o, every post went to my garbage folder
Reply With Quote
  #57  
Old 06-17-2005, 06:17 PM
Kruppa Kruppa is offline
 
Join Date: Apr 2003
Location: Canada
Posts: 41
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by lifesbattles
ugh o, every post went to my garbage folder
Yeah that happened to me as well. Thank goodness I had a backup from about a week ago because I was in for some serious thread moving.

This hack was a good idea, but it's very annoying to have to move back the stickies every day this script runs. It works great without the stickies bit.
Reply With Quote
  #58  
Old 06-24-2005, 04:10 PM
Sinistra's Avatar
Sinistra Sinistra is offline
 
Join Date: Jun 2005
Posts: 190
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OK I am running 3.0.7 The sticky thing dosen't work any suggestions on how to fix it?
Code:
error_reporting(E_ALL & ~E_NOTICE);

if ($DB_site == NULL)
{
	exit;
}

global $DB_site;

 // edit the forum id number
$newforum="25";

// you only need to edit the number of days only
$movedate = strtotime("now -14 days");


// do not edit below

  $DB_site->query("
UPDATE " . TABLE_PREFIX . "thread
SET forumid = $newforum
Where lastpost <= $movedate
AND forumid != $newforum
OR sticky != 1
"); 

log_cron_action('Auto Move Threads To Archive', $nextitem);
Reply With Quote
  #59  
Old 11-06-2005, 03:42 PM
debear debear is offline
 
Join Date: Jun 2004
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great! This looks like what I need to archive my 2004 posts to a 2004 Archive forum. I want it to maintain the forum structure and be readable, but not postable. I want them to also be searchable.

This looks like the 2 version is for annual moves which is what I need. But it looks like it is for older versions.

Has anyone tried this on version 3.5 yet? And did it leave the stickies?

Thanks for your work on this guys.
Reply With Quote
  #60  
Old 12-16-2005, 11:58 AM
Julie's Avatar
Julie Julie is offline
 
Join Date: Mar 2005
Location: Oslo, Norway
Posts: 187
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by cinq
Nice one, sure could use this !

Possible to also do one "Auto Close thread after 100 posts and create a new one with the same title" ( but append a part X to it where X is 2 if the new post created has been branched once, 3 if branched twice and so on .. ) and with the first post of this new thread to have the content : " In continuation of this previous thread here: XX )" where XX is the link to the previous closed thread ?

Have always been meaning to try something like this for my forums but never got round to doing it.

Hope you can release something like this, since you seem to be on a roll with these cron jobs trafix
I too would like something like that. As I have this "Band/Movie/Song/Etc Games".... And those topics should stop at 250 replies, and then a person starts a new one with the last band/movie/song/etc posted... The above request would be wicked Hehe...

I know it's a long while since this was posted, but... *poke* You alive?
Reply With Quote
  #61  
Old 01-03-2006, 05:30 PM
Dactyld Dactyld is offline
 
Join Date: Aug 2005
Posts: 10
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Crap how do you undo this? I want to put the posts back and can't figure out how.
Reply With Quote
Reply

Thread Tools

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 09:16 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.05148 seconds
  • Memory Usage 2,302KB
  • 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
  • (1)bbcode_code
  • (1)bbcode_php
  • (4)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