// focuses the first form element with an error

$(document).ready(function(){

  $(".errorfocus:first").focus();

});

