Does anybody have experience with wysihtml5 for rails?  I have installed
the WYSIWYG editor and it is working fine, but I'm not sure how to
manipulate any of its characteristics.  I want to hide the buttons on
some occasions and more importantly need to set it to a read only mode
on a particular page so users can click on URL's in the WYSIWYG text
area.

My current setup...
gem 'wysihtml5-rails'  in gemfile

In "show' page...

<%= text_area_tag  id="ck_a", @formatted_question[:anno_a],
:class=>'wysihtml5' %>

               <script type="text/javascript">
      $('.wysihtml5').each(function(i, elem) {
        $(elem).wysihtml5();
      });
    </script>

Also, not sure why but only works when <script
type="text/javascript">...</script>
is below the text_area_tag in the body of the page.

I'm half way through Heads UP Javascript book to give you an idea of my
level of programming ability, so thanks for the help!

-- 
Posted via http://www.ruby-forum.com/.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to