I am trying to collect the index of my combo box. I would like to be able to change the index, and then have a bunch of fields changed based on the new index. Am I doing this right so far?
Thanks.
<script type="text/javascript">
function getCombo(sel) {
var value = sel.options[sel.selectedIndex];
$.get(document, {type: value});
}
</script>
// Misc code here
<td class="bold"><label for='addType'>Select Type to Add : </label>
<select name="addType" id="combo" onchange="getCombo(this)">
<option value="book">Book</option>
<option value="author">Author</option>
<option value ="publisher">Publisher</option>
<option value="customer">Customer</option>
</select>
<?php
$type['type'] = $_GET['value'];
?></td>