Author |
Topic |
Davio
Development Team Member
Jamaica
12217 Posts |
Posted - 21 September 2006 : 20:12:14
|
Mod Name: Merge Topic Mod Version: Beta 2 Snitz Forums Tested with: 3.4.05 and newer (should be able to work with all 3.4 versions) Database support: All database types supported Author: Davio Last Updated: September 25, 2006.
Description: This mod allows you to merge 2 topics together, along with all of their replies. Replies will be ordered by their post date.
Download: Primary site: http://www.snitzbitz.com/mods/details.asp?Version=All&mid=233
To-Do: - Add feature to email author that his topic was merged with another. - Handling of subscriptions need to be dealt with for both topics being merged. - Maybe get a better icon to use? - Fix bugs!
Known Bugs: - When merging 2 topics between 2 different forums, the merged topic ends up in the wrong forum. FIXED in beta 2
You guys have been asking me for this code for the longest while. So here it is. It is not fully ready for prime time. There is still some things left on the To-Do list and some bugs to iron out. But hoping with your help, we can get it there more quickly, instead of waiting on me.
Please don't use this on your live forum as yet. If you do, don't come and blame anyone here that your topics got messed up.
Please post your bug reports, errors, suggestions in this thread.< |
Support Snitz Forums
|
Edited by - Davio on 25 September 2006 05:38:49 |
|
sachin
Starting Member
14 Posts |
Posted - 21 September 2006 : 22:01:34
|
Thnx a lot Davio... will test it soon :)< |
|
|
Davio
Development Team Member
Jamaica
12217 Posts |
Posted - 22 September 2006 : 16:52:19
|
Ok, I see the logic of my coding in the post_info.asp file needs a little more working on.
I'm using the older topic, the topic that has the older date, as the target topic. But when you merging between 2 forums, there is no way to find out which topic the mod/admin wants to merge with, using this logic. Because he could be merging an older topic with a newer topic.
So it will need a little recoding there.
Identify the topic mod/admin wants to merge with, then after, sort out which topic is older and let it remain as the main topic. The replies can come afterwards.
Did you all get that? This thing is busting my brains. lol< |
Support Snitz Forums
|
Edited by - Davio on 22 September 2006 16:54:06 |
|
|
rasure
Junior Member
289 Posts |
Posted - 23 September 2006 : 16:57:34
|
Hi Davio, I get this error when merging 2 topic in the same forum
quote: Microsoft JET Database Engine error '80040e14' Syntax error (missing operator) in query expression 'M.MEMBER_ID = T.T_AUTHOR AND T.TOPIC_ID ='. /forums/post_info.asp, line 1833
quote: if lcase(strEmail) = "1" then 'Send mail to author letting him know his topic was merged with another. 'DoAutoMoveEmail(allRec(Topic_ID, intOlderTopic)) strSql = "SELECT M.MEMBER_ID, M.M_NAME, M.M_EMAIL, T.FORUM_ID, T.T_SUBJECT " strSql = strSql & " FROM " & strMemberTablePrefix & "MEMBERS M, " & strActivePrefix & "TOPICS T " strSql = strSql & " WHERE M.MEMBER_ID = T.T_AUTHOR " strSql = strSql & " AND T.TOPIC_ID = " & TopicNum 'Response.Write strSql 'Response.End line 1833 set rs2 = my_Conn.Execute (strSql) email = rs2("M_EMAIL") user_name = rs2("M_NAME") Topic_Title = rs2("T_SUBJECT") ForumId = rs2("FORUM_ID") Usernum = rs2("MEMBER_ID") rs2.close
not sure if that's related to your above post, btw I also have your split topic mod installed on an already moded snitz, and I used the complete url to the topic to merge to, not sure if that's the correct way of doing it.< |
Psychic & Spiritual Development Resources |
Edited by - rasure on 23 September 2006 17:24:14 |
|
|
Davio
Development Team Member
Jamaica
12217 Posts |
Posted - 25 September 2006 : 02:21:23
|
Yes, that part of the code is on the to-do list. Has to do with sending an email out to the author about what is happening with his topic. Can comment out that part of the code or change the 1 in this line " if lcase(strEmail) = "1" then" to 0. That will effectively turn off that section of the code.
Still busting my brains with the code when merging topics from different forums. Works if the topic is in the same forum though.< |
Support Snitz Forums
|
|
|
Davio
Development Team Member
Jamaica
12217 Posts |
Posted - 25 September 2006 : 05:39:05
|
Ok, lets move on to BETA 2!
I think I fixed the bug with merging topics across forums. Only thing changed was the Merge Topic Mod code in post_info.asp. So copy the code from lines 957 - 1313 in post_info.asp to update to BETA 2.
Things you can test. 1. Merge topics in same forum. 2. Merge topics from different forums. 3. Merge topics and give it a new subject. 4. Do #1 and monitor the Topic and Replies count on default.asp 5. Do #2 and monitor the Topic and Replies count on default.asp 6. Merge topics with no replies. 7. Merge topics with replies. 8. Make sure the last post links point to the last posted reply or topic.
I have disabled the subscription section of the code, so you won't run into any errors while testing.< |
Support Snitz Forums
|
|
|
OneWayMule
Dev. Team Member & Support Moderator
Austria
4969 Posts |
|
OneWayMule
Dev. Team Member & Support Moderator
Austria
4969 Posts |
|
Davio
Development Team Member
Jamaica
12217 Posts |
Posted - 26 September 2006 : 09:46:08
|
Excellent! Thanks OneWay! Whew! Glad I got the main part working. But it's not feature complete yet. Need to alert authors when moving their topics around. They will be totally lost without it.
Also need to take care when merging with moderated topics/replies. And to email subscribers that there are new replies to the topic they subscribed to.< |
Support Snitz Forums
|
Edited by - Davio on 26 September 2006 10:03:14 |
|
|
Davio
Development Team Member
Jamaica
12217 Posts |
Posted - 26 September 2006 : 10:06:44
|
OneWay, just out of curiosity, I checked the snitzbitz site a while ago and it showed the mod was downloaded 0 times since I uploaded it. How was it you downloaded the mod and the counter didn't increase?
I just downloaded it and it increased by 1. Strange.< |
Support Snitz Forums
|
|
|
OneWayMule
Dev. Team Member & Support Moderator
Austria
4969 Posts |
|
Davio
Development Team Member
Jamaica
12217 Posts |
Posted - 27 September 2006 : 02:50:43
|
So was it beta 1 you tested or beta 2? Cause beta 1 was still buggy. lol< |
Support Snitz Forums
|
|
|
OneWayMule
Dev. Team Member & Support Moderator
Austria
4969 Posts |
|
rasure
Junior Member
289 Posts |
|
blackinwhite
Average Member
Turkey
657 Posts |
Posted - 25 November 2006 : 07:51:10
|
1. Merge topics in same forum. ok 2. Merge topics from different forums. ok 3. Merge topics and give it a new subject. ok 4. Do #1 and monitor the Topic and Replies count on default.asp ok 5. Do #2 and monitor the Topic and Replies count on default.asp ok 6. Merge topics with no replies. ok 7. Merge topics with replies. ok 8. Make sure the last post links point to the last posted reply or topic. ok
AS you already say it, only problem I see is the lack of subscription function. Dou you have any plan to work on subscriptions or should i start to write my own?
thanks for the great work, I really appreciate it.< |
|
|
blackinwhite
Average Member
Turkey
657 Posts |
Posted - 25 November 2006 : 14:47:06
|
and about icon :) thre reverse version of split topic icon will do the work ;)< |
|
|
Topic |
|