I’ve been working on a website the past few days using Radiant CMS. So far, I have found it to be an excellent lightweight framework. The core concepts are very straightforward and there is minimal abstraction from the underlying Rails application.CMS in general is a dirty word to me. It conjures up pictures of heavy beasts like Drupal. Don’t get me wrong - Drupal has its place and time. But not for most one or two person sites. You can totally avoid a CMS system altogether as it is not hard to build up a little Rails application. However, it is harder to hand it off to non-Rails people to update regularly.Radiant is nearly the perfect blend. It uses intelligent structures for organizing the components of your site while leaving the underlying Rails structure available. So far, I have been able to do most of what I want via the built-in admin interface. It stores the bulk of your content in a database.The general philosophy is to create one of three pieces - pages, snippets, or layouts. The choice of pages is great. Many CMS systems make it difficult to get to what you really are building - web pages. Instead, Radiant lets you get right to work on the page content and uses helpers for rendering the finished pages.Pages are composed of parts which are regions of content on a page. For example, most of my pages have a body part (the default) and a sidebar part. Layouts are the templates shared by multiple pages. Layouts map very closely to Rails layouts. So you can easily use the same design patterns. I have a layout for the normal web pages and one for the RSS feed. The last piece is a snippet which nicely map very closely to Rails helpers. Again, use the same patterns. My snippets include a header, footer, and navbar.In addition, Radiant has a concept similar to ERB - radius. These tags are filled in by Radiant. For example, you can get all the child pages of the current page via radius tags. You can get other attributes like the title, author, or date. Finally, there is a nice navigation helper set of tags that lets you build an intelligent navbar.Radiant supports several different markup meta languages like Markdown, SmartyPants, and Textile. I’ve had a little trouble mixing the Radiant tags (radius) with these. They might only be useful for parts that aren’t dependent on the radius tags.There are a couple things I don’t like. First, you can’t easily re-order your page hierarchies. I had to create a new page and copy content to move it in the tree. Also, if you want to do news items or blog posts, you treat them as pages. I think it might be a little better to somehow push these into a separate posts concept. The interface with the style sheets isn’t the best. Stylesheets are simply pages as well. This works except that it is tedious to put the CSS changes in if you want to use another tool like Coda or TextMate. The last problem is that all the structure and content are mashed together in the database. Ideally, I would like to have the structure parts in source control (templates, containers, snippets, stylesheets, etc) and the actual content in the database. It might be possible to hack Radiant to do this but so far I haven’t had the motivation to do so.Overall this is a nice site development platform. It isn’t strictly a blogging system and it doesn’t have the massive list of features of other CMS systems. It is a great choice if you could write the site by hand but don’t want to spend that much time or effort. To see a full-featured example, checkout the official Ruby language site. It is built using Radiant.
-
« Home
-
Categories
Comments 1
The state of cms/blogging software on rails is still weak. Maybe it is because of what you said, that it is so easy to build a cms in a couple of hours. But still I think the RoR community should go with one and strengthen it. Something like mephisto, typo, or radiant could be great contenders to wordpress if their roadmaps got more serious.
Posted 09 Oct 2007 at 6:37 ¶Trackbacks & Pingbacks 1
[...] Andrew Carter has an interesting piece on Radiant CMS on Rails. [...]
Post a Comment