ruby on rails 3 - Rails3 setting focus on a textfield -


when have errors in form, set focus first textfield error. i've done php , javascript in past, i'm not sure how approach in rails3.

thanks in advance

<%= javascript_tag "$('foo_bar').focus()" %> 

Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -