0

Possible Duplicate:
HTML5 form required attribute. Set custom validation message?

in HTML 5 form validation

<form>
<input type="txt" required id="username"/>
</form>

this required filed will always shows the message "Please enter filed"

Is there a way to customize this message ?

Community
  • 1
  • 1
Sudantha
  • 15,684
  • 43
  • 105
  • 161

2 Answers2

3

Not all browsers will support this attribute, Firefox does support it, IE and chrome no. I dont know about the other browsers.

using value="Your value" mentioned above won't work. i just tried it.

i guess we have to wait till HTML5 becomes stable. to find out

Rami Sarieddine
  • 5,396
  • 35
  • 41
1
<input type="txt" required id="username" value="Your value" />
patapizza
  • 2,398
  • 15
  • 14