I am interested in adding a blog to my Ruby on Rails app. I do not want to waste my time coding up a bloggin app in rails - I can do it but I just prefer something more robust.

I have investigated Wordpress and it seems like one of the best bloggin platforms out there. My question is how would I get Wordpress integrated into my site? I would preferably like to use my existing rails layouts and CSS. Is this type of thing even possible.

My site is http://www.arenpatel.com/ and as an end result I would like to have the same Rails generated sidebar (Twitter feed) on the blog.

Maybe there is a Rails alternative to Wordpress?

Thanks for the help!

asked Aug 28 '11 at 18:21

4 Answers 4

You can integrate a jekyll style blog with markdown files for blog posts very easily using the rails engine Postmarkdown.

Edit: Updated URL.

answered Aug 28 '11 at 23:15

8

  • I'll check it out once its released as a RubyGem

    Aug 29 '11 at 0:01

  • how do I install it otherwise?

    Aug 29 '11 at 1:29

  • figured it out cd Gemfile then gem build postmarkdown.gemspec then gem install postmarkdown-0.0.1.gem

    Aug 29 '11 at 1:31

  • Or in your Gemfile you can specify :git => git://url

    Aug 29 '11 at 4:53

To integrate WP, install Wordpress in a subdirectory, like /blog. So you'd have http://arenpatel.com/blog. Make the WP blog's home page the index / front page of the WP installation. You would have to manually port your layout in some shape or fashion into the WP theme. I can't think of a good way to share that, especially any dynamic code. You could share the same css using an @import statement in the WP theme's style.css (a required file). Wordpress works fine in this screnario.

I don't think there is anything in the Ruby world that does everything WP does, but maybe that's not necessary in your case???

answered Aug 28 '11 at 18:42

2

  • Okay so I basically added the wordpress to my app's public folder. I was able to setup the database connection using the wordpress setup steps, but when I now try to hit arenpatel.com/wordpress I get a page does not exist error!

    Aug 28 '11 at 18:56

  • I even see in the database that the wordpress comments, users, posts tables have all been created... I just can't access wordpress portion via the browser what gives?

    Aug 28 '11 at 19:01

Im not sure how well php and ruby play together under the same directory so the easies way i see is to host a Wordpress blog under a subdomain, for example, http://blog.arenpatel.com/.

You will of course have to write you own (or alter an existing) theme for wordpress in order to make it look the way your rails app does. You can read all about it here: http://codex.wordpress.org/Theme_Development

As for your twitter feed; there are a bunch of plugins for wordpress do the same thing. All you will have to do is to style it via css.

Cheers!

answered Aug 28 '11 at 18:48

answered Dec 21 '15 at 0:21

Not the answer you're looking for? Browse other questions tagged ruby-on-rails ruby-on-rails-3 wordpress or ask your own question.