[geeklog-cvs] geeklog: fixed duplicate topics bug
geeklog-cvs at lists.geeklog.net
geeklog-cvs at lists.geeklog.net
Fri Mar 26 23:01:18 EDT 2010
changeset 7835:ce94a8b05250
url: http://project.geeklog.net/cgi-bin/hgwebdir.cgi/geeklog/rev/ce94a8b05250
user: stan <stan at spalatnik.com>
date: Fri Mar 26 23:01:01 2010 -0400
description:
fixed duplicate topics bug
diffstat:
public_html/admin/topic.php | 4 +++-
public_html/layout/professional/admin/topic/topiceditor.thtml | 1 +
2 files changed, 4 insertions(+), 1 deletions(-)
diffs (32 lines):
diff -r ffd1a2e42531 -r ce94a8b05250 public_html/admin/topic.php
--- a/public_html/admin/topic.php Thu Mar 25 21:56:43 2010 +0200
+++ b/public_html/admin/topic.php Fri Mar 26 23:01:01 2010 -0400
@@ -240,6 +240,7 @@
$topic_templates->set_var ('archive_disabled', 'disabled');
}
}
+ $topic_templates->set_var('oldid', 'oldID');
if (empty($tid)) {
$num_stories = $LANG_ADMIN['na'];
@@ -340,7 +341,8 @@
DB_query ("UPDATE {$_TABLES['topics']} SET archive_flag = 0 WHERE archive_flag = 1");
}
}
-
+
+ DB_query("DELETE FROM {$_TABLES['topics']} WHERE tid = '{$_POST['oldID']}'");
DB_save($_TABLES['topics'],'tid, topic, imageurl, meta_description, meta_keywords, sortnum, limitnews, is_default, archive_flag, owner_id, group_id, perm_owner, perm_group, perm_members, perm_anon',"'$tid', '$topic', '$imageurl', '$meta_description', '$meta_keywords','$sortnum','$limitnews',$is_default,'$is_archive',$owner_id,$group_id,$perm_owner,$perm_group,$perm_members,$perm_anon");
// update feed(s) and Older Stories block
diff -r ffd1a2e42531 -r ce94a8b05250 public_html/layout/professional/admin/topic/topiceditor.thtml
--- a/public_html/layout/professional/admin/topic/topiceditor.thtml Thu Mar 25 21:56:43 2010 +0200
+++ b/public_html/layout/professional/admin/topic/topiceditor.thtml Fri Mar 26 23:01:01 2010 -0400
@@ -90,6 +90,7 @@
<input type="submit" value="{lang_cancel}" name="mode"{xhtml}>
{delete_option}
<input type="hidden" name="{gltoken_name}" value="{gltoken}"{xhtml}>
+ <input type="hidden" name="{oldid}" value="{topic_id}"{xhtml}>
</td>
</tr>
</table>
More information about the geeklog-cvs
mailing list