Subhadip Chakraborty wrote:
hi, i am currently using rails version 2.2.2. and using fckeditor_textarea. here is the code:
<%= fckeditor_textarea(:emailcontent,:body, {:toolbarSet => 'Basic', :width => '100%', :height => '100%'}) %> where emailcontent is the model(object) name, and body is method. but it's not working,however same code is working in any version below 2.2.2. The error is undefined method 'relative_url_root'. Any reason? Thanks.
There is been a Fix for Rails 2.2
in the file app/controllers/fckeditor_controller.rb look for uploaded = request.relative_url_root.to_s+"#{UPLOADED}/#{params[:Type]}"
replace it with this uploaded = ActionController::Base.relative_url_root.to_s+"#{UPLOADED}/#{params[:Type]}"
similarly in the file lib/fckeditor.rb replace js_path = "#{request.relative_url_root}/javascripts" with js_path = "#{ActionController::Base.relative_url_root}/javascripts"
reference:
this worked for me.