I\'m using the following HTML code to autoselect some text in a form field when a user clicks on the field:
This works best for me...
The mouseup event fires after onfocus.