How to link the existing discourse comments to wordpress posts?

(david) #1

I have setup wp-discourse, and checked syncing is fine between wordpress post and discourse for new posts.(they are hosted in different domains)
Currently I have bunch of existing comments in discourse, which comes from disqus.
I want to connect them to the relative topics in wordpress.
But It’s not working at all.
What’s the best way to link each other? I have been seeking for this answer for 3 days.

(Josiah Toppin) #2

I’m unclear as to what you’re asking here. How did you import the disqus comments into Discourse in the first place?

(Simon Cossar) #3

As things are now, it is not possible to use the plugin to link existing Discourse comments to a new WordPress post. The plugin works by creating a new Discourse topic when you select ‘Publish to Discourse’ on the WordPress admin page. The linking is done by setting the WordPress post meta-data 'discourse_permalink' to the value of the Discourse topic’s topic_slug.

It looks like it would be possible to add a feature to the plugin to ‘link to existing Discourse topic’. It would have to be supplied with either the topic_slug or or the topic URL from Discourse. That’s not going to happen right away though.

How to enable Discourse comments via JavaScript in Wordpress?
(david) #5

Btw,I imported discourse comments by disqus_importer script which is provided by discourse org.
But now I can’t link them to the related wordpress topics. Seems like linking by each topic’s slug is the only way, But there is no such feature right now. What should I do now?
thanks for your support.Waiting for your reply.

(david) #6

The one which are creating by wp-discourse are working perfectly. Syncing is fine right now.
But can’t find the solution to linking existing discourse topics.
Please help me.

(Simon Cossar) #7

For now you could try embedding the existing comments with javascript. See this topic for details:

Look at the section labeled ‘(Alternate Configuration) Linking to existing topics’.

(Erlend Sogge Heggen) #8

I definitely support this for v1.1. Let’s come back to it after v1.0 is published. Further discussion on this feature can go here:

(Quintin Par) #9

Hello wonderful people,

Did anyone pick this up, yet? Looking to link existing blog post and existing discourse topics.

(Simon Cossar) #10

Yes, it exists in my development branch of the wp-discourse-shortcodes plugin. I think it works better as a shortcode than by adding it as an option to the Publish to Discourse metabox. I’m not sure what is the best way to include this in the wp-discourse plugin. The shortcode could either be added to wp-discourse, or kept in the shortcodes plugin. In either case, I’ll get it ready to go soon.

How to enable Discourse comments via JavaScript in Wordpress?
(Quintin Par) #11

Thank you. I can be your tester.

If I use the short code plugin and let’s say we connect it with an id similar to this

how do I customize (look) what’s shown below the blog post? Will the theme settings carry on from the discourse forum?

(Quim Gil) #12

For what is worth, the use case of connecting manually WP posts to Discourse topics looks (to me at least) closely related to the core functionality that the wp-discourse plugin provides. I installed this plugin yesterday and immediately missed such feature.

The functionality provided by wp-discourse-shortcodes is more of a nice to have, and the plugin itself is presented as more experimental. I for one would go for wp-discourse plugin. :slight_smile: