To automatically set the focus to a specific control when the page loads use autofocus, e.g. <input type="text" name="fname" autofocus>