Possible Duplicate:
Set cursor at a length of 14 onfocus of a textbox
I am able to do that in firefox and IE. But for some reason its not working in Chrome and Safari :(
I am simply using below line onfocus
$('input:text').focus(
function(){
document.getElementById('id').setSelectionRange(0, 0);
});
Can someone please tell me how to do similar thing in Chrome and safari?