MyBB Community Forums

Full Version: When merging threads, use newer ID?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, I have a bit of a unique situation. I have a Wordpress plugin that automatically generates a thread on my forums whenever I post a news story. The plugin uses the ID of the forum thread it created to show posts from the forum thread on the Wordpress comments page.

However, sometimes, my forum visitors will beat me to a news story, start a topic on it, and carry on pages of discussion before I am able to create a news story on the front page of my site. Our normal protocol is to lock these threads once I get my story up along with its discussion thread, but we'd rather just merge the two threads together. The only problem is that when we do this, because their discussion thread is older, myBB uses the ID number of the older discussion thread and adds the posts in from the new one the WP plugin created. This causes the Wordpress post to display no posts from the forums since it can't find the thread and leads to a bunch of other errors.

So, is there a way to force myBB to use the ID of the newer thread when merging the posts together? Instead of deleting the Wordpress-generated thread (the newer one) and moving its posts to the older user-generated thread, it deletes their thread and its ID and moves their posts to the new thread? Or just anything that would allow me to keep the ID of the thread Wordpress creates and add their posts in somehow?

Thank you! Smile