Tansheet Ali Taj
Tansheet Ali Taj

Reputation: 45

Input text selection not working properly on double-click

When double-clicking on a html page most browsers select the word you double-click on (or the paragraph you triple-click on). But it is not working properly on my html page specially for input field.

Upvotes: 2

Views: 2595

Answers (1)

Shahzaib Zafar
Shahzaib Zafar

Reputation: 36

<input type="text" class="abc" id="abc" name="xyz" ondblclick="this.select()" value="">

you can Selet the value of input field by using ondblclick="this.select()"

Upvotes: 2

Related Questions