Onblur and Onfocus in input field that can't be edited

phat

New Member
I have an input field like this:\[code\] <input class="" type="text" id="Name_11_1" name="Name" value="http://stackoverflow.com/questions/15657431/Your name:">\[/code\]And want to change it into this:\[code\]<input class="" type="text" id="Name_11_1" name="Name" value="http://stackoverflow.com/questions/15657431/Your name:" onblur="this.value = http://stackoverflow.com/questions/15657431/this.value || this.defaultValue;" onfocus="this.value =http://stackoverflow.com/questions/15657431/= this.defaultValue && (this.value ='');"Your name:">\[/code\]The problem is that I CAN'T edit the input field directly and have to use an external javascript code, but my js level is inder newbie, so every help would be greatly appreciated
 
Back
Top