$('[value=""]') seems to be broken in 1.3.1 (fixed in the nightlies, see http://dev.jquery.com/ticket/3990), so that would be
$('form input[value=]:first').focus(); cheers, - ricardo On Feb 4, 7:38 pm, Klaus Hartl <klaus.ha...@googlemail.com> wrote: > $('form input[value=""]:first').focus(); > > --Klaus > > On 4 Feb., 20:57, Massiverse <august.massive...@gmail.com> wrote: > > > Hello > > > I'm a newbie, here's what I need to do (searched the forums first but > > couldn't find the answer). > > > 1. Search form for an empty input field. > > 2. If an empty field exists, set the focus on the field. > > 3. If no empty fields exist, do nothing. > > > Thanks, > > > August