
jQuery script to hide certain form fields
By: a guest on
Feb 21st, 2012 | syntax:
jQuery | size: 0.36 KB | hits: 2,578 | expires: Never
/*! jQuery script to hide certain form fields */
$(document).ready(function() {
//Hide the field initially
$("#hide1").hide();
//Show the text field only when the third option is chosen - this doesn't
$('#awesome').change(function() {
if ($("#awesome").val() == "Nope") {
$("#hide1").show();
}
else {
$("#hide1").hide();
}
});
});