Several times with the Wordpress plugin I’ve removed a link to one topic, saved the post, and then attempted to add a link to different existing topic, only to get this error:
There has been an error linking this post with Discourse. Make sure you are supplying the URL of an existing topic on your forum.
Any ideas how I can fix this? Or is it a bug others can reproduce?
You will get the error you are reporting if the domain of the topic you are attempting to link to doesn’t match the domain of the Discourse URL you have entered on the plugin’s Connection Settings tab. Does this sound correct for your case?
No. It’s the same domain that it auto-posts to. Just a different topic. Just checked the domain and it is correct. I doubt auto-posting would work if that setting was wrong.
No. We are on Communiteq (formerly DiscourseHosting).
Oddly I know this used to work. I don’t know when it stopped working, but the change must have been upgrading either Discourse itself or the Wordpress plugin. I’m pretty sure nothing else in settings changed.
I don’t think anything has changed in the plugin’s code for linking topics recently. Have there been any recent changes to your WordPress site? For example, have you moved it to new hosting, or changed the version of PHP that it’s using?
The domain name is parsed from the URL with wp_parse_url. It is possible that it’s not parsing the domain correctly.