Scott Rutherford

Life on and off the Rails

 

FCKeditor Demo

December 28th, 2006

I have been asked a few times for the code for the FCKeditor demo. So I thought I would put it up here for anyone to download, and by here I mean here.

The tar includes the fckeditor plugin, the ajax scaffold plugin and the bits to get them working together. You will need to create a db and update the config files though.

FCKeditor and FireFox

December 18th, 2006

A few people have said they have been having problems with the text area not appearing in Firefox. This isn’t a problem I have had but for those of you who have, thanks to James Penny there is a solution…..

Simply add something like :width => ‘400’, :height => ‘200’ to the fckeditor_textarea call and you should get the editor appearing as expected. Obviously you can change the dimensions to suite your needs.

The solution also explains why I never saw the issue – I have always had the dimensions specified…...

FCKeditor 0.4.0 Released

December 3rd, 2006

I released a new version of the FCKeditor plugin today. It contains a couple of changes to the controller to fix a potential security issue and also a remote_form_for helper so that now you can do this:

<% fckeditor_remote_form_for :note,
                             :url => @options.merge(:controller => 'notes'),    
                             :editors => { :note => ['text'] } do |f| %>
  <%= fckeditor_textarea( "note", "text", :ajax => true )
<% end %>

You still need to use the original fckeditor_textarea call as as of yet there is no f.fckeditor_textarea method.

I am currently trying to add a check for IsDirty to prevent accidental unloading of the editor and also looking at using the FCKeditor_IsCompatibleBrowser() function to degrade gracefully.

N.B If you are upgrading you will need to delete the public/javascripts/fckeditor directory before reinstalling…

This blog used the Shay theme as a base and is powered by Mephisto