Author |
Topic |
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
Posted - 14 February 2001 : 21:36:58
|
NOTE: DOWNLOAD URL CHANGED
Name: Snitz Archiver Author: Huwr and I Version: 1.0 FINAL Download: http://www.stormwhispers.com/snitz_testing/forums_archive.zip Support: http://stimmy.cfm-resources.com Demo: http://195.149.32.155/mushroomgrove/ Description: Allows you to archive and delete topics from forum to forum. Installation: Download and extract files to your forum folder, and run mod_dbsetup.asp from your browser. Also add a link to admin_home.asp linking to admin_forums.asp, or using Mod Commander.
strSQL = "SELECT TOPIC_ID FROM " & strTablePrefix & "ARCHIVE_TOPICS WHERE FORUM_ID=" & rsForum("FORUM_ID") set rsArchive = my_conn.execute (strSQL) if not rsArchive.eof then Response.Write " <a href=""archive.asp?FORUM_ID=" & rsForum("FORUM_ID") & "&CAT_ID=" & rsForum("CAT_ID") & "&Forum_Title=" & ChkString(rsForum("F_SUBJECT"),"urlpath") & """>" Response.Write "<img src=""article.gif"" height=15 width=15 border=0 hspace=0 alt=""View Archived posts""></a>" end if rsArchive.close
Add the above after the following, around line 350 in default.asp
if rsForum("F_TYPE") = 0 then if rs("CAT_STATUS") = 0 then Response.Write " <a href=""forum.asp?FORUM_ID=" & rsForum("FORUM_ID") & "&CAT_ID=" & rsForum("CAT_ID") & "&Forum_Title=" & ChkString(rsForum("F_SUBJECT"),"urlpath") & """>" if rsForum("F_LAST_POST") > Session(strCookieURL & "last_here_date") then Response.Write "<img src=""" & strImageURL & "icon_folder_new_locked.gif"" height=15 width=15 border=0 hspace=0 alt=""Category Locked""></a>" else Response.Write "<img src=""" & strImageURL & "icon_folder_locked.gif"" height=15 width=15 border=0 hspace=0 alt=""Category Locked""></a>" end if else if rsForum("F_STATUS") <> 0 then Response.Write " <a href=""forum.asp?FORUM_ID=" & rsForum("FORUM_ID") & "&CAT_ID=" & rsForum("CAT_ID") & "&Forum_Title=" & ChkString(rsForum("F_SUBJECT"),"urlpath") & """>" & ChkIsNew(rsForum("F_LAST_POST"),"") & "</a>" else Response.Write " <a href=""forum.asp?FORUM_ID=" & rsForum("FORUM_ID") & "&CAT_ID=" & rsForum("CAT_ID") & "&Forum_Title=" & ChkString(rsForum("F_SUBJECT"),"urlpath") & """>" if rsForum("F_LAST_POST") > Session(strCookieURL & "last_here_date") then Response.Write "<img src=""" & strImageURL & "icon_folder_new_locked.gif"" height=15 width=15 border=0 hspace=0 alt=""Forum Locked""></a>" else Response.Write "<img src=""" & strImageURL & "icon_folder_locked.gif"" height=15 width=15 border=0 hspace=0 alt=""Forum Locked""></a>" end if end if end if
DISCLAIMER: This is beta, which means it is still buggy. It is recommended only to be used on testing forums at this point. It is however, pretty safe up to this point.
I have just included a .mod file for those with Mod Commander
---- Da_Stimulator Snitz Forums Dev Team Member http://stimmy.cfm-resources.com/forum - my testing forums.
Edited by - da_stimulator on 14 February 2001 21:48:30
Edited by - da_stimulator on 14 February 2001 23:15:15
Edited by - da_stimulator on 15 February 2001 01:30:17
Edited by - da_stimulator on 15 February 2001 02:46:24
Edited by - da_stimulator on 15 February 2001 02:48:14
Edited by - da_stimulator on 15 February 2001 17:43:07
Edited by - da_stimulator on 18 February 2001 20:33:04 |
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
|
HuwR
Forum Admin
United Kingdom
20584 Posts |
Posted - 14 February 2001 : 21:45:20
|
they will need a link to admin_forums.asp somewhere, so they can do the archiving.
|
|
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
Posted - 14 February 2001 : 21:46:14
|
Oh yeah.... Speaking of which, where can I get mod commander???
---- Da_Stimulator Snitz Forums Dev Team Member http://stimmy.cfm-resources.com/forum - my testing forums. |
|
|
HuwR
Forum Admin
United Kingdom
20584 Posts |
Posted - 14 February 2001 : 21:53:32
|
if you look in the copleted mods forum in my file attachment topic, download the required files .zip, ignore the stuff about config, just get the mod commander files from it
|
|
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
|
HuwR
Forum Admin
United Kingdom
20584 Posts |
Posted - 14 February 2001 : 22:39:31
|
I've discovered a prob, when it archives the replies, it archives all replies older than the date specified, and does the same to Topics, so if you have a reply to the topic which is newer than the archive date, you will loose it because it will delete the topic from FORUM_TOPICS.
FIX
Change the topic delete SQL to
strsql = "delete from " & strTablePrefix & "TOPICS where TOPIC_ID=" & drs("TOPIC_ID") & " AND T_LAST_POST < '" & fdateolderthan & "'"
Then it will archive the topic and the old replies, but will leave any topics with new replies in FORUM_TOPIC so you can still get at the other posts.
Edited by - huwr on 14 February 2001 22:40:32
Edited by - huwr on 14 February 2001 22:41:15 |
|
|
HuwR
Forum Admin
United Kingdom
20584 Posts |
Posted - 14 February 2001 : 22:56:39
|
and change the reply delete for archiving to this
strsql = "delete from " & strTablePrefix & "REPLY where TOPIC_ID=" & drs("TOPIC_ID") & "AND R_DATE < '" & fdateolderthan & "'"
|
|
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
Posted - 14 February 2001 : 23:07:29
|
Is this in the archive sub or the delete sub?
---- Da_Stimulator Snitz Forums Dev Team Member http://stimmy.cfm-resources.com/forum - my testing forums. |
|
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
Posted - 15 February 2001 : 01:29:22
|
Demo has been added, Huwr is currently using it at his Testing facility :) http://195.149.32.155/mushroomgrove/
Also the zip has been updated with a .mod file for those with Mod Commander.
---- Da_Stimulator Snitz Forums Dev Team Member http://stimmy.cfm-resources.com/forum - my testing forums.
Edited by - da_stimulator on 15 February 2001 02:47:18 |
|
|
rick7165
Senior Member
USA
1094 Posts |
Posted - 15 February 2001 : 02:57:55
|
Da Stimulator & HuwR... I want to tell you guys something... I have the worst luck with Mods.. Ask HuwR! LOL
I installed this Mod... It fell right in and worked like a Charm!!!
GREAT Job Guys!!!! Keep Up the Good Work!
Thank You.
Test Site www.eastpasco.com Running on HuwR's SR4 release. Colors and Graphic scheme done by Richard Kinser.
Edited by - rick7165 on 15 February 2001 03:20:20
Edited by - rick7165 on 15 February 2001 04:25:30 |
|
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
Posted - 15 February 2001 : 03:07:13
|
Kewl... even though I'm now into developing mods, I'm not the best with setting them up either.
Glad you could get it set up nice and easily!
---- Da_Stimulator Snitz Forums Dev Team Member http://stimmy.cfm-resources.com/forum - my testing forums. |
|
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
Posted - 15 February 2001 : 03:28:58
|
Rick, that only shows up if there are archived topics for that forum. The code to do that is under the instructions in the main topic post.
---- Da_Stimulator Snitz Forums Dev Team Member http://stimmy.cfm-resources.com/forum - my testing forums. |
|
|
Da_Stimulator
DEV Team Forum Moderator
USA
3373 Posts |
Posted - 15 February 2001 : 04:07:58
|
simply put a <br> just in front of the <a href=".....
---- Da_Stimulator Snitz Forums Dev Team Member http://stimmy.cfm-resources.com/forum - my testing forums. |
|
|
rick7165
Senior Member
USA
1094 Posts |
Posted - 15 February 2001 : 04:23:24
|
Thanks
You can delete these so people can post problems..
Thanks Again!
quote:
simply put a <br> just in front of the <a href=".....
---- Da_Stimulator Snitz Forums Dev Team Member http://stimmy.cfm-resources.com/forum - my testing forums.
Test Site www.eastpasco.com Running on HuwR's SR4 release. Colors and Graphic scheme done by Richard Kinser. |
|
|
Topic |
|