I recently had to do something similar using jQuery.
First, hide the download area so that the user cannot see it.
<style>
#div2appear{
display: none;
}
</style>
Then the elements of the form
<form id="AllTheseFields">
<input type="checkbox" name="c1" />
<input type="checkbox" name="c1" />
<input type="checkbox" name="c1" />
<input type="checkbox" name="c1" />
<input type="checkbox" name="c1" />
<div id="div2appear">
<input type="text" />
</div>
</form>
And jQuery
<script type="text/javascript">
$('#AllTheseFields>input[type=checkbox]').change(
function(){
if($('#AllTheseFields>input[type=checkbox]').is(':checked')){
$('#div2appear').show();
}else{
$('#div2appear').hide();
}
}
);
</script>
kamui source
share