Expand textbox on focus using jQuery
Here is jQuery code to expand the textbox onfocus using jQuery. Below code animate and expand the width of a TextBox when it receives focus.
$(document).ready(function() { $('#txtSearch').width(150); $('#txtSearch').focus(function() { $(this).animate({ width: 250 }) }); $('#txtSearch').blur(function() { $(this).animate({ width: 150 }) }); });?
See result below.
See Complete Code
Feel free to contact me for any help related to jQuery, I will gladly help you.