jquery - How can i disabled partially a input? -
i have part in input disabled. input field subdomain, want this
xxxxxx.mydomain.com
only x must editable, not domain, possible?
you can use this:
$('input').on('focus',function(){ return $(this).val($(this).val().split('.')[0]).select(); }); $('input').on('change focusout',function(){ return $(this).val($(this).val() + '.mydomain.com'); });
Comments
Post a Comment