Computer Magic Logo
Highlight Text in an input

Monday, June 12, 2017

Published by Aristotelis Pitaridis

We can make the visitors life easier by automatically highlighting the contents of an input in order to easily replace the contents. The following code demonstrates how to do it.

$("#username").select();