Question
Making an email form dynamic?
I have a registration form here:
www.pitlanepass.com/pages/register.php
I'm in the very early stage of learning php so the form is created in dreamweaver and emailmeform.com so save that bullet for later!!
I have populated several fields using a mysql database and they display and email in a format i'm happy with. for now. The small issue I have is when the organisation is selected and the next field (class) is displayed it lists all classes from the four organisations. Some are repeated and the list is uneccessarily long. For example, Southern Supermoto has only 3 classes but lists all 25! This method allows a registrant to possibly select a class that doesn't exist. I've had similar issues elsewhere ith rider profiles but used $_GET to pull variables from the url but I don't think thats how to achieve it here. Any pointers would be most welcome!!
Here's the code snippet from the form...<label>Organisation</label>
<select name="FieldData1">
<?php do { ?>
<option value="<?php echo $row_rsRegisterorgselect['orgname']; ?>"><?php echo $row_rsRegisterorgselect['orgname']; ?></option>
<?php } while ($row_rsRegisterorgselect = mysql_fetch_assoc($rsRegisterorgselect)); ?>
</select>
<br />
<label>Class</label>
<select name="FieldData2">
<?php do { ?>
<option value="<?php echo $row_rsClassregister['catname']; ?>"><?php echo $row_rsClassregister['catname']; ?></option>
<?php } while ($row_rsClassregister = mysql_fetch_assoc($rsClassregister)); ?>
</select>