I''m writing a basic to-do application. I''m using a form_remote_tag to submit the entry to my controller, which then returns the entry to be displayed in the table of to-do items. However, I''d like to be able to "textilize" the entry without having to reload the page. Is there any way to have my ajax function textilize the text before displaying it in the list? If I try to textilize it in my controller, I get an "undefined method ''textilize''" error. Thanks! _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
See http://shnoo.gr/articles/2005/12/20/ajax-the-great. However, first you have to get "textilize" to work. I suspect you don''t have RedCloth installed. Try: gem install RedCloth. Josh http://shnoo.gr Dylan Markow wrote: I''m writing a basic to-do application. I''m using a form_remote_tag to submit the entry to my controller, which then returns the entry to be displayed in the table of to-do items. However, I''d like to be able to "textilize" the entry without having to reload the page. Is there any way to have my ajax function textilize the text before displaying it in the list? If I try to textilize it in my controller, I get an "undefined method ''textilize''" error. Thanks! -- Posted via http://www.ruby-forum.com/.
Using a partial worked. I had RedCloth installed, but it seems that the textilize function only works in RHTML files, not RB files? Thanks! Joshua Harvey wrote: See http://shnoo.gr/articles/2005/12/20/ajax-the-great. However, first you have to get "textilize" to work. I suspect you don''t have RedCloth installed. Try: gem install RedCloth. Josh http://shnoo.gr Dylan Markow wrote: I''m writing a basic to-do application. I''m using a form_remote_tag to submit the entry to my controller, which then returns the entry to be displayed in the table of to-do items. However, I''d like to be able to "textilize" the entry without having to reload the page. Is there any way to have my ajax function textilize the text before displaying it in the list? If I try to textilize it in my controller, I get an "undefined method ''textilize''" error. Thanks! _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails