Q:

versatile blog for ruby on rails, password protection?

Hey guys, I am making a personal website with a blog. I'd like to have certain entries password protected like I've seen on at least one wordpress. That's no biggie. But I was wondering if there was something really flexible which will allow hidden text to be revealed after a post? For example, the public post may say, "I met my friend Bob for coffee today" but upon putting in the personal password, some text tagged as being private will be like, "Bob stinks!!" Also, I'll want different layers of privacy for friends,family members, etc. Not sure how to tie it all together but I don't even know much about the blog world in Ruby - is there anything that's extensible enough that I could put together these features myself without having to reinvent the wheel?

A:

There are several authorization plugins for Rails that have view helpers that only display that markup when the user has appropriate access. So a family member could see Bob stinks!, but the guest would only see the public post. Javascript is probably overkill for this, unless you want to show the hidden data without refreshing the page.
acl_system2 has the restrict_to method. CanCan has the can? view helper method. Here are some other authorization gems/plugins.

