I recently published a plugin that helps you turn any textarea into a markup editor. It is based on excellent markItUp! jQuery plugin.
Example
The most simple usage with preset defaults
<html>
<head>
<%= javascript_include_tag "path/to/jquery" %>
<%= mark_it_up '#miu_test' %>
</head>
<body>
<%= form_tag do %>
<%= text_area_tag "miu_test" %>
<% end %>
</body>
</html>
You can see a lot more cool examples in action on markitup.cingel.hr.
More info
I could not get this to work out of the box with rails 3. Will you be updating the plugin to work with rails 3, and time soon.
thanks
@HAB100
I will do my best to add Rails 3 support in the near future, till then you will have to replace
< %= mark_it_up '#miu_test' %>with< %= raw mark_it_up '#miu_test' %>I just did a quick fix so it should now work out of the box in Rails 3.
Pingback: Tweets that mention MarkItUp: Rails plugin that turns any textarea into a markup editor | Kolodvor -- Topsy.com
Hi,
Great to see someone ported this great editor to Rails. However I can’t get it to run in my Rails 3.1 app. It just says: undefined method ‘mark_it_up’ when I follow the steps on the Git.
Something I’m doing wrong or something incompatible with 3.1?
Hi Jelle. I didn’t try it with Rails 3.1 yet. I’ll try that ASAP and let you know how it went.
Hi again, I just made some updates and test it on 3.1.3 and everything works. Go to https://github.com/cingel/mark_it_up for updated readme file.
Cheers
I tried it and it’s working perfectly now thanks!
Glad to hear it works.