Q: javascript enabling input boxes I got a form that looks like this:
<form method="POST" name="emails" action="../emailing.php">
<select size="1" id="email_template" name="email_template_id">
<option value="1">Welcome</option>
<option value="2">Newsletter</option>
<option value="3">Invoice</option>
</select>

<input type="hidden" name="email_template" value="1">
<input type="hidden" name="saleid" value="318">
<input type="hidden" name="usertype" value="admin">
<input type="image" name="emails" id="imageField" src="/images/submit.gif" class="send">
</form>    

On that page where that dropdown shows up i need another input boxes to show up but ONLY when the Invoice option is selected.
Like an Input field (or 2) and maybe a text area for some random text to be entered.
These extra fields should also be sent with the form.

A: Ok, just grab the change event of your drop down like this:
<select size="1" id="email_template" name="email_template_id" onchange="ddlEmail_Change(this)">
...

Then on your javascript, you have something like this:
function ddlEmail_Change(source){
   var selValue = source[source.selectedIndex].value;

   document.getElementById('extra-fields').style.display = (selValue =="3" ? 'block' : 'none');
}

And the extra-fields, actually is a div that you add bellow your drop down like this:
<div id="extra-fields" style="display:none">
   <!-- extra fields goes here, this shows up when option 3 is selected -->
</div>

I've not tested this but it should work!
