This plugin allows you to specify the form element on which the initial focus should be set
Using it is as simple as calling:
$('form > input:first').formFocus();
Please note: jQuery selectors that return more than one element are not supported as only one element can receive the keyboard focus at a time.