Onblur event in js? Help!
-
Hi guys
I’m trying to make a onblur javascript event, which should help our administration team, by doing less editing when the form is submitted.
Normaly it would look something likes this:
<script type="text/javascript"> function Capitalize() { var precapitalize = document.getElementById("myidfield").value; var capitalized = precapitalize.substr(0, 1).toUpperCase() + precapitalize.substr(1); document.getElementById("myidfield").value = capitalized; } </script> <input type="text" name="test" value="test" id="myidfield" size="40" onblur="Capitalize();">
I’ve tried to make a normal Html field input with a Contact Form 7 class, BUT the field have to be required, and I do not know how to make it looks like CF7’s validation.
<input type="text" name="test class="wpcf7-form-control wpcf7-text">
Does anyone knows how i can call an Onblur event on Contact Form 7?
OR does anyone knows how i can make a html field required just like a normal Contact Form 7 field?
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Onblur event in js? Help!’ is closed to new replies.