Custom Links in User Profile

I want my users to be able to insert links in their profile, but obviously they can't use html.

I want to solve this by allowing them to do [link="http://theirurl.com"][/link]. Any idea how I would go about this?

Thanks!

I would consider using Textile or Markdown. Take a look at the RedCloth gem. http://whytheluckystiff.net/ruby/redcloth/

-Dan Manges http://www.dcmanges.com/blog

linker = Regexp.new(/\[link="(.*?)"](.*?)\[\/link]/)

<%= @user.profile.gsub(linker){|m| "<a href='#{m[0]}' class='whatever'>#{m[1]}</a>"} %>