It\'s fairly straightforward. I want to set focus to the first enabled and not hidden control on the page.
For a textbox, I have
$(\"input[type=\'t
As an extension of Jordan's answer
$(':input:enabled:visible:not([readonly]):first').focus();
This one also excludes readonly inputs