New Rails 1.2.1 Error with text_area

I just upgraded to Rails 1.2.1, and I’m suddenly seeing this area
whenever my code calls for a text_area (this code has been working for
a long while in 1.1.6:

private method `split’ called for 60:Fixnum

The code surrounding the error is…

12:

<%= text_area ‘link’, ‘description’, :size => 60,
:rows => 2 %>

The app trace looks like this…

C:/Program
Files/ruby/lib/ruby/gems/1.8/gems/actionpack-1.13.1/lib/action_view/helpers/form_helper.rb:288:in
to_text_area_tag' C:/Program Files/ruby/lib/ruby/gems/1.8/gems/actionpack-1.13.1/lib/action_view/helpers/form_helper.rb:190:intext_area’
#{RAILS_ROOT}/app/views/links/_form.rhtml:12:in
_run_rhtml_47app47views47links47_form46rhtml' #{RAILS_ROOT}/app/views/links/new.rhtml:17:in_run_rhtml_47app47views47links47new46rhtml’
-e:4

Has anyone else come across this error, and knows of a solution?

Thanks!

Hi Egon,

I just upgraded to Rails 1.2.1, and I’m suddenly seeing this area
whenever my code calls for a text_area (this code has been
working for a long while in 1.1.6:

private method `split’ called for 60:Fixnum

The code surrounding the error is…

12:

<%= text_area ‘link’, ‘description’, :size => 60,
:rows => 2 %>

Try :
<%= text_area ‘link’, ‘description’, size => ‘60x2’ %>

– Jean-François.


À la renverse.

Think I might have found the answer, though I’m not really sure why
it’s an issue.

If I remove the :size => 60 clause from the text_area, everything
works fine.

Jean-François wrote:

Try :
<%= text_area ‘link’, ‘description’, size => ‘60x2’ %>

– Jean-François.

That worked great! Thanks!

Andrew F. wrote:

Just a thought, but the textarea HTML tag uses rows and cols attributes
to define its dimensions (or CSS seems to work too).

Hope that helps,
Andrew

Ah. Good point. That’d likely be the correct place to do it-- get it
out of the .rhtml altogether.

12:

<%= text_area ‘link’, ‘description’, :size => 60,
:rows => 2 %>

Just a thought, but the textarea HTML tag uses rows and cols attributes
to define its dimensions (or CSS seems to work too).

Hope that helps,
Andrew