Displaying 1 result from an estimated 1 matches for "fieldfocus".
2006 Apr 14
0
Masked Input Fields?
...uby on Rails have a form helper function to create a masked text input
field? For example, a mask for entering a phone number might look like:
( ) -
Also, does RoR have a function to set the focus to the first form field on a
page? I usually use the following JavaScript function:
function FieldFocus() {
if (document.forms.length > 0) {
document.forms[0].elements[0].focus();
}
}
along with:
<body onLoad="FieldFocus()">
But, if Rails comes with similar functionality built in I''d rather do it the
Rails way.
Kevin
http://www.RawFedDogs.net
http://...