I've a textbox with readonly="readonly" that means I can not edit it. But what I want is to make this textbox editable when user double clicks on it.
What I've tried yet is:
<input size="10" readonly="readonly" ondblclick="setEditable(this)"/>
and in JavaScript:
function setEditable(i){
i.readonly = false;
}
But this does not worked. So how can I make a textbox editable, which is readonly, when user double clicks on it?