vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Mini Mods - ZH - Auto Lock Thread (https://vborg.vbsupport.ru/showthread.php?t=165618)

Ziki 12-18-2007 10:00 PM

ZH - Auto Lock Thread
 
This modification was brought to you by
KXDesign
http://www.kxdesign.com/


~Modification name
Auto Lock Thread

~Modification description
Locks an old thread after X amount of days.

~Modification options
  • Turn on/off
  • Choose thread id's
  • Choose amount of days

~Modification info
File uploads: 0
Template edits: 0
File edits: 0
Plugins: 1
SQL Queries: 0
Phrases: 7
Settings: 3

Install time: 3 sec
Install level: Easy

~Modification installation
Step 1: Import Product



~Modification screenshots
None


~Modification copyright
This may not be distributed,released or claimed as your work without author's permission.

Ziki 12-19-2007 06:51 PM

~Reserved~

johnr 12-19-2007 08:40 PM

Do you have any plans to expand this hack?

It would be really useful to me if I could lock a thread after x days of inactivity.

Amenadiel 12-19-2007 09:03 PM

Quote:

Originally Posted by johnr (Post 1404955)
Do you have any plans to expand this hack?

It would be really useful to me if I could lock a thread after x days of inactivity.

That's easy, you should edit the xml before importing and on line 25, where it says:

PHP Code:

WHERE threadid IN($zhthread) AND open AND sticky AND dateline ".intval(TIMENOW-(86400*$zhtime)) 

replace it with

PHP Code:

WHERE threadid IN($zhthread) AND open AND sticky AND lastpost ".intval(TIMENOW-(86400*$zhtime)) 


I haven't seen vb_thread table structure for vb3.7, but I'm pretty sure "lastpost" field is still there. ;)

Ba$im 12-20-2007 09:06 AM

thanx.

Snake 12-21-2007 02:31 PM

Thanks!

Cyrus [Hwluxx] 12-25-2007 01:10 PM

Any Suggestions if you expand this Hack to close Threads after xxx Posts ?

stwilson 01-26-2008 06:33 PM

Can you apply this MOD to specific forums or is it thread specific?

Rich 02-07-2008 08:52 PM

This mod is not very user friendly if we have to enter each threads ID individually. I recall a version where you entered the forum ID, or something like that, and it would close every thread that was "x" amount of days old. Is this one also going to have that added functionality or is this the end product? (I ask because i need to know if I need to figure it out on my own. lol)

LuBi 02-10-2008 12:29 AM

I always enjoy a nice automated add-on like this. Thanks for taking the time and sharing it with us, this is a great start. I like some of the ideas I'm reading, may I also suggest this mod be able to move threads. I used to have a mod like this auto lock then move the locked thread to a sub-forum archive. It really made life easy and kept things clean. Thanks again.

majordork82 02-12-2008 11:55 PM

Quote:

Originally Posted by Cyrus [Hwluxx] (Post 1408871)
Any Suggestions if you expand this Hack to close Threads after xxx Posts ?

I've noticed a LOT of people asking for this, and I am looking for it as well. Can you modify this hack to do that?

Jase2 02-14-2008 11:44 PM

Could you get this work so that a thread is closed after x amount of posts and a new one created with the same title? And works per-forum basis?

Regards Jason

Strik3 03-24-2008 09:40 AM

Can you add a function for do this in ALL forums and after X days since the last posting?

DieselMinded 05-06-2008 02:37 AM

I added this to my support forum and it didnt close the threads

http://www.dieselbombers.com/diesel-...upport-ticket/

Is this for Forum Id's ??

DieselMinded 05-08-2008 07:41 PM

Any Ideas?

mgurain 05-21-2008 04:53 AM

Hi,
Could you add options like:
- include forum ids:
- exclude forum ids:

thanks,,

libabom 08-20-2008 08:34 AM

close Threads after xxx Posts ?

yathyo 09-21-2008 04:05 PM

Doesnt works :(

Ziki 10-17-2008 10:42 AM

A new fixed version is available here: http://www.kxdesign.com/vb-3-7-add-o...ck-thread.html

This now includes multiple thread options!

Desesperao 10-21-2008 11:37 AM

Sorry but I've dowloaded the hack of this link:

http://www.kxdesign.com/vb-3-7-add-o...ck-thread.html

... and it's the same as here.

Desesperao 10-21-2008 07:53 PM

Close Threads after xxx DAYS ?

Is it possible?

Ziki 10-22-2008 05:01 AM

Why shouldn't it be?

Triky 10-22-2008 09:20 AM

Would be great if "Locks threads after X amount of posts" and open a new one with the same author, same title (with a [1] at the beginning. eg. "[1] My Title").. and a link to the old closed one.

Ziki 10-22-2008 09:32 AM

You are a coder,I am sure you can add that feature ;)

Triky 10-22-2008 10:20 AM

Ever wanted to do, never succeeded becouse I'm not a *good* coder. I still need to learn correctly HTML, LOL.

Ziki 10-22-2008 11:34 AM

That code would be purely PHP ;)

Desesperao 10-27-2008 09:39 PM

Sorry, Ziki

What I was searching is this:

https://vborg.vbsupport.ru/showthread.php?t=148117

Thank's for your great effort. ;)


All times are GMT. The time now is 07:14 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01181 seconds
  • Memory Usage 1,767KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (27)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete