I have an input type button (it can not be submit type because it triggers a secondary action inside a form) that I need to maintain disabled if no selection made on a previous dropdown selector. I have unsuccessfuly tried: this, this, this, and some others...
here it is my form code :
echo "<select class='corpusname' id='corpusname' size='1' name='corpusname' required />
<option value=''>Select a corpus</option>";
// This query gives the other options from a database
$result = mysqli_query($db, "SELECT * FROM corpus_info") or die(mysqli_error($db));
while($cpsmlg = mysqli_fetch_array($result)){
echo "<option value='".$cpsmlg['corpus']."'>".$cpsmlg['title']."</option>";
}
echo "</select>
<a id='theLink' target='_blank'>
// This is the button to be disabled
<input type='button' id='seedoc' class='seedoc' value='See doc' /></a>";