I am getting an error called there i开发者_Python百科s no attribute "onFocus". I have a code as follows:
<input name="name" id="name" class="small required name" type="text" value="Name:" onFocus="if(this.value='Name:'){this.value=''}" />
I tried validating my site in http://validator.w3.org/, and I got these errors. Can anyone help me to resolve this issue?
The attribute name is onfocus
, with a small f
. That's what the validator is complaining about.
精彩评论