jQuery(document).ready(function($) {
$('input[type="text"]').live('focus', function() {
if (this.value == 'someValue') {
this.select();
}
});
});
The same result with .delegate() and .on().
What am I missing?
Any help is appreciated.
Works fine for me using
.on. Perhaps you want it to select the text when you click?Fiddle: http://jsfiddle.net/jonathansampson/nfKm7/