Simple Machines Community Forum

SMF Development => Bug Reports => Fixed or Bogus Bugs => Topic started by: digger on December 27, 2017, 01:52:36 AM

Title: Not a bug, but wrong behavior
Post by: digger on December 27, 2017, 01:52:36 AM
We have a forum links to the messages like this
index.php?topic=1.msg123
If we move this message to another topic, the current link for the message will be
index.php?topic=2.msg123
But if we click on the old link index.php?topic=1.msg123 we'll get into the wrong location in the first topic, and not where the message 123 is now.

Title: Re: Not a bug, but wrong behavior
Post by: Aleksi "Lex" Kilpinen on December 27, 2017, 07:52:31 AM
I believe this is intended behavior. The message ID is unique, and allows for links like this
https://www.simplemachines.org/community/index.php?msg=3954194
so you can directly point to a message anywhere in the forum, without knowing the board or topic it is in.

Title: Re: Not a bug, but wrong behavior
Post by: digger on December 27, 2017, 08:00:46 AM
Quote from: Aleksi "Lex" Kilpinen on December 27, 2017, 07:52:31 AM
I believe this is intended behavior. The message ID is unique, and allows for links like this
https://www.simplemachines.org/community/index.php?msg=3954194
so you can directly point to a message anywhere in the forum, without knowing the board or topic it is in.
Such links are not displayed anywhere in the forum and they can only be created manually.
Usually all users copy a message link from the title of the message and this link is https://www.simplemachines.org/community/index.php?topic=557937.msg3954194#msg3954194
Title: Re: Not a bug, but wrong behavior
Post by: Arantor on December 27, 2017, 08:01:49 AM
It's completely intended behaviour because it's possible SMF will generate topic=1.msg234 links where the message doesn't exist but relies on it matching the next message in the topic after that id.

Also the msg= link is created for quotes in 2.1 and probably should be used for the permalink as well.
Title: Re: Not a bug, but wrong behavior
Post by: Sesquipedalian on February 21, 2018, 03:11:19 AM
Quote from: Arantor on December 27, 2017, 08:01:49 AM
Also the msg= link is created for quotes in 2.1 and probably should be used for the permalink as well.

https://github.com/SimpleMachines/SMF2.1/pull/4555