Skip to content

Instantly share code, notes, and snippets.

@andhikamaheva
Last active August 29, 2015 14:14
Show Gist options
  • Save andhikamaheva/a48d2bfa339765da86eb to your computer and use it in GitHub Desktop.
Save andhikamaheva/a48d2bfa339765da86eb to your computer and use it in GitHub Desktop.
You can using this script to change required notification in text field
<form id="form" onsubmit="return(login())">
<input name="username" placeholder="Username" required title="Username Anda" oninvalid="this.setCustomValidity('Username harus diisi')"
onchange="this.setCustomValidity('')" type="text" />
<input name="pass" type="password" placeholder="Password" oninvalid="this.setCustomValidity('Password harus diisi')" onchange="this.setCustomValidity('')" required />
<br/>Remember me: <input type="checkbox" name="remember" value="true" /><br/>
<input type="submit" name="submit" value="Log In"/>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment