Blog post plugin

Awesome work!!

Love the look of that. :slight_smile:

thanks for the plugin, but I couldn’t make it work on my forum. the book icon doesn’t show up.

The plugin’s README isn’t as clear as it should be, so hopefully that is the problem.

Have you enabled the plugin and added any categories for creating blog-posts in? Are you a member of a group that is in the ‘blog post allowed groups’ setting?

If so, if the plugin is working correctly, the book icon should be in the hidden post-menu icons for categories that you have enabled.

If you have added an image to the post, after clicking the book icon you will need to refresh, or revisit, the topic to see the image in the topic’s header.

If you have done all this and it’s still not working, what version of Discourse are you using? What other plugins do you have on your forum? Are you able to check your browser’s console and see if there are any errors there?

1 Like

thanks, the problem was with the way I added the blog category to the list:

previously I’ve added /c/blog as the category slug, and as shown in the images it should be blog .

are admins able to turn this blog-option on for a post written by a user without the privileges?

1 Like

Yes, an admin can turn it on and off for any user. Otherwise, only the topic owner can, if they are in an allowed group.

1 Like

just a quick test, I could run it on a newly built category and I couldn’t run it on a previously existing category.

so should the category be built freshly (without topics) to be able to use the plugin?

BTW, nice format and nice work :smiley: thanks for the plugin .

You should be able to use it an a previously existing category. I’ll take a look. Is your category name in Persian?

3 Likes

yes, the name is in Persian but the slug is English. and when I put the name instead of the slug, it worked!

Thanks for the clue :blush:

1 Like

May the Discourse team ever be willing to endorse this plugin and make it available on their managed hosting? If so, what would need to be done / updated in the plugin to make it suitable? Or does it contradict to the main kit’s idea of never being a blog-like thing on its own?

When I’d installed this plugin, it’s conflicting with Quick Message Plugin functionality and the generated error is related to Blog post plugin. For more details please review the below link.

Thanks for reporting that. I was trying to get the category without first making sure that there was a category. It should be fixed now.

https://github.com/scossar/discourse-blog-post/blob/master/plugin.rb#L115

2 Likes

Thank you for your quick reply.

I’m getting the following error now after I’d re-enabled Blog Post plugin. The following error repeated 4 times at the same minute!

failed to deliver message, skipping #<struct MessageBus::Message global_id=247486, message_id=363, channel="/writing-reply", data={"channel_id"=>"279", "user_id"=>"3"}>
 ex: Couldn't find Topic with 'id'=279 [WHERE ("topics"."deleted_at" IS NULL)] backtrace: ["/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activerecord-4.2.7.1/lib/active_record/relation/finder_methods.rb:324:in `raise_record_not_found_exception!'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activerecord-4.2.7.1/lib/active_record/relation/finder_methods.rb:444:in `find_one'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activerecord-4.2.7.1/lib/active_record/relation/finder_methods.rb:423:in `find_with_ids'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activerecord-4.2.7.1/lib/active_record/relation/finder_methods.rb:71:in `find'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activerecord-4.2.7.1/lib/active_record/querying.rb:3:in `find'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activerecord-4.2.7.1/lib/active_record/core.rb:131:in `find'", "/var/www/discourse/plugins/discourse-presence/plugin.rb:49:in `block (2 levels) in activate!'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:535:in `block (2 levels) in global_subscribe_thread'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:549:in `each'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:549:in `block in multi_each'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:548:in `each'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:548:in `multi_each'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:533:in `block in global_subscribe_thread'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus/backends/redis.rb:331:in `block (2 levels) in global_subscribe'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/subscribe.rb:45:in `block in subscription'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:141:in `block (3 levels) in call_loop'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:135:in `loop'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:135:in `block (2 levels) in call_loop'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:231:in `block (2 levels) in process'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:367:in `ensure_connected'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:221:in `block in process'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:306:in `logging'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:220:in `process'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:134:in `block in call_loop'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:280:in `with_socket_timeout'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:133:in `call_loop'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/subscribe.rb:43:in `subscription'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/subscribe.rb:12:in `subscribe'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:2760:in `_subscription'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:2138:in `block in subscribe'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:58:in `block in synchronize'", "/usr/local/lib/ruby/2.3.0/monitor.rb:214:in `mon_synchronize'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:58:in `synchronize'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:2137:in `subscribe'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus/backends/redis.rb:304:in `global_subscribe'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:513:in `global_subscribe_thread'", "/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:461:in `block in new_subscriber_thread'

Backtrace

/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/logster-1.2.5/lib/logster/logger.rb:76:in `add_with_opts'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/logster-1.2.5/lib/logster/logger.rb:37:in `add'
/usr/local/lib/ruby/2.3.0/logger.rb:498:in `warn'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:537:in `rescue in block (2 levels) in global_subscribe_thread'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:534:in `block (2 levels) in global_subscribe_thread'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:549:in `each'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:549:in `block in multi_each'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:548:in `each'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:548:in `multi_each'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:533:in `block in global_subscribe_thread'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus/backends/redis.rb:331:in `block (2 levels) in global_subscribe'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/subscribe.rb:45:in `block in subscription'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:141:in `block (3 levels) in call_loop'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:135:in `loop'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:135:in `block (2 levels) in call_loop'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:231:in `block (2 levels) in process'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:367:in `ensure_connected'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:221:in `block in process'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:306:in `logging'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:220:in `process'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:134:in `block in call_loop'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:280:in `with_socket_timeout'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/client.rb:133:in `call_loop'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/subscribe.rb:43:in `subscription'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis/subscribe.rb:12:in `subscribe'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:2760:in `_subscription'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:2138:in `block in subscribe'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:58:in `block in synchronize'
/usr/local/lib/ruby/2.3.0/monitor.rb:214:in `mon_synchronize'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:58:in `synchronize'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/redis-3.3.1/lib/redis.rb:2137:in `subscribe'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus/backends/redis.rb:304:in `global_subscribe'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:513:in `global_subscribe_thread'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/message_bus-2.0.2/lib/message_bus.rb:461:in `block in new_subscriber_thread'

Edit:
When I’ve got this error I’d made just two actions (after rebuilding). I deleted a post, and I created another post. Then I did noticed these errors. But now I’m trying to replicate the errors. It didn’t happened again. I’ll be watching and I’ll report here if anything I catch again!

I’ll look at that, but I can’t do it today. Remove the blog-post plugin for now.

2 Likes

It’s not likely to happen, mostly for the reasons you already mentioned. While it’s a cool feature, it’s very niche and has not been requested by a lot of customers. Many tools do blogging way better than Discourse ever will, so our primary focus will be on interoperability with these specialised tools.

3 Likes

This plugin doesn’t work on the latest master branch. Having it installed shouldn’t break your site, it just won’t create a blog post. I have a fix for it here: https://github.com/scossar/discourse-blog-post/tree/update-for-ember-2.1. I’ll merge that into the plugin’s master branch in the next couple of days.

2 Likes

pls can i use this plugin in my site (laptop2all.com) and how ?

If you have a Discourse forum you can install it. I looked at your site. I don’t see a forum there.

If you have a website and a forum, you don’t need this plugin. Just create your posts on the website and then link from the post to the discussion on the forum. The wp-discourse WordPress plugin is good for doing that.

Hi guys!

Does that plugin compatible with 1.8 Discourse?

Yes it works, but installing a third party plugin on Discourse is always risky. Unless you really need it, I think that a better solution is to create blog posts on a WordPress site and use this WordPress plugin to connect your forum with a blog: WP Discourse 1.0.0 release

3 Likes

I installed this plugin on Discourse v2.0.0.beta4 and it does not work.
The install went fine, and there are plugin settings in the dashboard, but there book icon does not appear to turn a post into the specially formatted blog post.

I would really like to use this, if possible.

Since it seems that this plugin is basically deprecated, is there any other plugin that allows for alternate formatting for specific posts or categories?