Image links not appearing when published to Wordpress

Thanks @Canapin.

@Full30 There are a few ways this can occur as the WP Discourse plugin does some minor HTML parsing, then Discourse also does some HTML parsing, and re-scraping. The link stripping is most likely occurring in Discourse’s HTML parsing and re-scraping i.e. in the way Discourse handles HTML embedded in posts. For example see

Or

Rather than seek a “technical” fix, my specific advice here is to separate links from images, e.g. by using a link underneath the image. I understand that you’d prefer to keep them as one, however you’re going to be fighting an uphill battle on that front to get it working consistently. Separating them may work.

Essentially, Discourse does not aim for HTML fidelity on imported posts. It aims for content fidelity for the purposes of discussion. Your Wordpress > Discourse strategy should be framed with that in mind, meaning that you want your users to be reading the post on Wordpress, with the version of it on Discourse just there as a reference for discussion.

2 Likes