Posted By

genik on 05/05/11


Tagged

jquery focus


Versions (?)

Focus To The First Text Input Element


 / Published in: jQuery
 

Set focus to the first text input element on a html document.

  1. $('input[type=text]:eq(0)').focus();

Report this snippet  

Comments

RSS Icon Subscribe to comments
Posted By: prwhitehead on May 5, 2011

this would also move the browsers view port to the first input element though right?

You need to login to post a comment.