I have the following form:
<form action="http://www.tahara.es/contact/subscribe.php" method="post" id="subscribe" name="subscribe">
<input type="hidden" name="action" value="subscribe">
<label>NAME:</label>
<input type="text" name="name" class="Textbox" id="sub_first_name">
<label>EMAIL:</label>
<input type="text" name="email" class="Textbox" id="sub_email">
<input type="submit" name="button" id="button" value="Subscribe" />
I would like to grey out the submit button until both fields in the form have been filled out. I guess jquery would do the trick?
How can I do this, and where should I place the script?
Jquery would do that. On the .keyup event have jquery check if both field’s lengths are > 0 and change the button to be disabled or not.