Store the original id; when it's reinserted it will take its original place.
Oh, that sounds messy to me... How so? [merge id=12345 date=67890]?
And even then, it can be a problem if someone starts playing with the tag to use an existing message ID in it, things like that... Things could go wrong. That's not something I'd see myself do, really -- the potential mess is horrible.
Heck, I don't even think we can insert a message ID and set the id_msg manually. It'll always rely on autoincrement. And I don't see myself modifying the table on the fly to remove the autoincrement flag and reset it later...
:PWith a single post being formed, any threaded replies would also be merged into that branch.
Err... No?
If you retain the two posts, you have to figure out how the final thread would be shown.
Hmm...?
Post 1 by Nao
Post 2 by Arantor
Post 3 by Nao
Post 4 by Nao
Becomes, to the user:
Post 1 by Nao
Post 2 by Arantor
Post 3 by Nao
Post 4
Post 4 has its own quote, edit buttons etc. Now, let's say I (not Nao) want to answer the part that is in post 3... I click the quote button there. I submit. I'll thus create a Post 5 with a parent ID that is post 3, not post 4 (it would be post 4 if posts 3 & 4 were actually merged like they are now.)
That is -- if I want to show a threaded view, I'll get this:
Post 1 by Nao
Post 2 by Arantor
Post 3 by Nao
Post 5 by Someone
Post 4 by Nao
(Whether or not we should show "by Nao" on Post 4 in threaded view is something we'd decide later on, depending on the layout and design.)
To me I think of posts as atomic items and merging double posts does seem logical to make the result atomic.
I'd like to know our users' opinion on this.
The whole double post thing isn't just about dealing with the signature and avatar and so on... it's also about keeping it a single post, in terms of management, in terms of replying to it, splitting and so on. I can see the wisdom of being able to split two merged posts, but at the same time I'm not keen on it looking like two posts; if I merge two posts I want one physical post.
We can always add a profile setting to view posts as a single one, as a series of separate posts, or as an in-between version with posts merged together but all buttons available for all posts.
Let's just say for now that I'm not against the idea but I'm not entirely sold on it yet.
'kay
;)