我在我的 Ruby on Rails 应用程序上工作,我是 Rails 的新手。我使用“form_for 标签”。enter code here
<%= f.label :password %>
<%= f.password_field :password%>
我需要在我的输入字段中添加“onkeyup”属性,以便在生成的 HTML 中看起来像这样:
<input type="password" id="password" onkeyup="checkPassword(this);" />;
我如何在 Rails 3 中做到这一点?