Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
a clone of textile_editor_helper (by Dave Olsen and Chris Scharf, modded by felttippin) with enhancements
branch: master

This branch is 1 commit ahead, 8 commits behind ryanfelton:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.


= Textile Editor Helper v0.3

Textile Editor Helper is a plugin for Ruby on Rails to add a Textile toolbar above textareas
This version of Textile Editor Helper is a fork of the code found at which in turn is a fork of the code found at felttippin's fork was created to allow for use with the form_for method. This fork has been created so that in addition, javascript/AJAX previews can be generated on the edit pages. Also want to implement some editor partial generation at some point for use with haml templates.

== Dependency

To use Textile Editor Helper you must be using either the Prototype or jQuery JavaScript libraries. If using Prototype, the Textile Editor Helper starts up on the 'dom:loaded' custom event. If using jQuery, it uses the $(document).ready() method.

== To use Textile Editor Helper

Directions to get the helper up and running for your install:

	1. run rake textile_editor_helper:install
	2. for the textarea(s) that you want to add the TEH toolbar to replace the text area tag with:

		<% form_for(:user, :url => user_path(@user), :html => { :method => :put }) do |f| %>
	  	<%= f.textile_editor :description %>
    <% end %>

		<%= form_tag :controller => "users", :action => "edit", :id => %>
			<%= textile_editor :user, "website" %>
		<%= textile_editor_tag 'description', :description -%> 
		**just like writing a text area tag, same options**

	3. at the end of your form put in the following code:

		<%= textile_editor_initialize -%> **Important!**
		If using jQuery, do textile_editor_initialize(:framework => :jquery)

	4. save your view and check it out

== Simple vs. Extended

TEH has a built-in mode to show only a sub-selection of available tags called simple. Currently the 'simple' tags are: bold, underline, italic, strikethrough. To create a text area that will only use the 'simple' tags create your text area with the following code:

	<%= textile_editor 'object', 'field', :simple -%>

== To modify Textile Editor Helper

Most of the options that you might want to modify (e.g. access keystroke or whether a tag is available in simple) are found in textile_editor_config.js. Pretty straightforward.

== More Info on Textile

To learn more about Textile check out: Textism, & Textile Reference,

== More Info on slate

slate is the CMS in development at West Virginia University that led to the development of Textile Editor Helper. Learn more at:

== License

Textile Editor Helper is released under the MIT license.

= Credits

Textile Editor Helper was created by Dave Olsen (Javascript) and Chris Scharf (Ruby/Rails) of West Virginia University Web Services (, modified by felttippin (github) and subsequently forked by metasoarous.

= Inspired by 

Patrick Woods, & 
Alex King,
Something went wrong with that request. Please try again.