Max Shytikov wrote in post #1084457:
> Only one solution you should use method  'tag' directly
> 
https://github.com/rails/rails/blob/39b9c943b7ec5181c19461d319d8c610ea1bf941/actionpack/lib/action_view/helpers/tag_helper.rb#L65

Thank you, This works!

But finally I ended making a

getElementById("name").onfocus = ...

on load instead of changing all my text_field_tag with tag

> P.S: Do not use inline JS .
You're right, but my problem is that I have ruby code in rhtml that 
generates css and javascript codes. These codes are not static but 
depend on ruby variables values.

I can't figure out how to pass a ruby variable into an external css or 
js file...

So I have to keep all the code in one big (sigh!) rhtml...

-- 
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