Here's a screenshot of what I'm trying to accomplish:

Basically, if the user chooses "SFTP", a textbox should be displayed.
Here's the code I have:
<strong class="heading">Image Hosting</strong>
<div id="imagehosting">
<form name="test">
Does the client require our company to host their images? <br />
<em>If you select this option, you'll have to specify what they will be using</em>
<input type="checkbox" name="category_level" onchange="categorychanged(this.checked)" />
<select name="category_parent" style="display:none" onchange="if(this.selectedIndex==SFTP){this.form['box'].style.visibility='visible'}else {this.form['box'].style.visibility='hidden'};">
<option value="1">Library</option>
<option value="2">SFTP</option>
</select>
<input style="visibility:hidden;" type="text" name="box">
</form>
<br />
</div>
The function, "categorychanged", is handled by the following Javascript code:
<script language="JavaScript" type="text/javascript">
<!--
function categorychanged(enable)
{
if (enable)
{
document.test.category_parent.style.display="block";
}
else
{
document.test.category_parent.style.display="none";
}
}
//-->
</script>
Right now, if I choose "SFTP", nothing happens. The first part works fine, i.e. dropdown displayed when the checkbox is selected.
What am I doing wrong here? Thanks