Javascript DOM HTML Input Text handle focus event

Introduction

Clear input field on focus:

View in separate window

<!DOCTYPE html>
<html>
<body>

<p>Clear the input field when it gets focus:</p>
<input type="text" onfocus="this.value=''" value="Blabla">

</body>/*  w w w .ja  v a2s.co m*/
</html>



PreviousNext

Related