Author |
Message |
Jim_UK Board Member
Joined: 19 Nov 2008
Posts: 656 Location: North West UK
|
Posted: Wed Sep 19, 2012 12:00 pm Post subject: Shadow topics |
|
|
When a topic is moved it should leave a shadow topic in the old forum provided it has been selected to do so. Unfortunately I have spotted that mine does not and I am unsure when it first stopped. Presumably due to some mod I have added.
Does anyone know where the bit of code that causes it to leave the shadow is to be found and what that code is so that I might compare mine with a fresh install to see what has gone wrong?
Thanks
Jim |
|
Back to top |
|
|
drathbun Board Member
Joined: 24 Jul 2008
Posts: 729 Location: Texas
|
Posted: Wed Sep 19, 2012 12:26 pm Post subject: Re: Shadow topics |
|
|
Jim, I can look that up, as some time back I removed the code as well. I don't like shadow topics. My first guess it that it's in modcp.php. _________________ phpBBDoctor Blog |
|
Back to top |
|
|
Jim_UK Board Member
Joined: 19 Nov 2008
Posts: 656 Location: North West UK
|
Posted: Wed Sep 19, 2012 12:38 pm Post subject: Re: Shadow topics |
|
|
Thanks Dave.
Jim |
|
Back to top |
|
|
dogs and things Board Member
Joined: 18 Nov 2008
Posts: 628 Location: Spain
|
Posted: Wed Sep 19, 2012 12:41 pm Post subject: Re: Shadow topics |
|
|
Is this it, in modcp.php?
Code: | if ( isset($HTTP_POST_VARS['move_leave_shadow']) )
{
// Insert topic in the old forum that indicates that the forum has moved.
$sql = "INSERT INTO " . TOPICS_TABLE . " (forum_id, topic_title, topic_poster, topic_time, topic_status, topic_type, topic_vote, topic_views, topic_replies, topic_first_post_id, topic_last_post_id, topic_moved_id)
VALUES ($old_forum_id, '" . addslashes(str_replace("\'", "''", $row[$i]['topic_title'])) . "', '" . str_replace("\'", "''", $row[$i]['topic_poster']) . "', " . $row[$i]['topic_time'] . ", " . TOPIC_MOVED . ", " . POST_NORMAL . ", " . $row[$i]['topic_vote'] . ", " . $row[$i]['topic_views'] . ", " . $row[$i]['topic_replies'] . ", " . $row[$i]['topic_first_post_id'] . ", " . $row[$i]['topic_last_post_id'] . ", $topic_id)";
if ( !$db->sql_query($sql) )
{
message_die(GENERAL_ERROR, 'Could not insert shadow topic', '', __LINE__, __FILE__, $sql);
}
} |
Greetings. _________________ phpBB2 will never die, I hope! |
|
Back to top |
|
|
Jim_UK Board Member
Joined: 19 Nov 2008
Posts: 656 Location: North West UK
|
Posted: Wed Sep 19, 2012 12:55 pm Post subject: Re: Shadow topics |
|
|
I will take a look later and see if I have "lost" that bit of code.
Thanks
Jim |
|
Back to top |
|
|
Jim_UK Board Member
Joined: 19 Nov 2008
Posts: 656 Location: North West UK
|
Posted: Fri Sep 21, 2012 3:03 am Post subject: Re: Shadow topics |
|
|
Unfortunately all that code was present and correct so the mystery deepens.
Jim |
|
Back to top |
|
|
drathbun Board Member
Joined: 24 Jul 2008
Posts: 729 Location: Texas
|
Posted: Fri Sep 21, 2012 4:26 pm Post subject: Re: Shadow topics |
|
|
If the code is there, then it may be that something on the form has changed and the variable $HTTP_POST_VARS['move_leave_shadow'] is no longer being set. _________________ phpBBDoctor Blog |
|
Back to top |
|
|
Jim_UK Board Member
Joined: 19 Nov 2008
Posts: 656 Location: North West UK
|
Posted: Sat Sep 22, 2012 3:31 am Post subject: Re: Shadow topics |
|
|
That is the next thing for me to check Dave. I will compare the template files using Winmerge to see if anything has vanished.
Personally I am not bothered about it not being there but a user compared my site to another where "they have a link from the original forum to the new location". It was only when he said that that I realised it had gone and of course that then got me wondering why.
Jim
Edit
Function now working. I wish that I had tested it myself earlier. Just took the users word that there was no link in old forum and did not test by simply looked at were the shadow should have been.
I guess which ever moderator moved it selected not to leave the shadow.
Next job is to have a word with them. |
|
Back to top |
|
|
|