So, here's what I have done. A number, 0-4, is being written to the
emailcollection table instead of the actual value that the user selects from. I made a new table in the same database, with the name of agerange, which contains four rows of data inside its two columns, id and description. It looks like this:
id | description
0 | -unspecified-
1 | 18-35
2 | 36-55
3 | 55+
4 | 17 or younger
<label for="age" class="fixedwidth">Select your age range:</label>
<select name="age" id="age" class="inputwidth">
<option selected="selected" value="0">Select an Age Range</option>
<option value="4">17 or younger</option>
Then, my friend had me do a JOIN query on the two tables, which apparently I have to do each and every time to get the actual age range to show.
What I want is for the age ID (The 0-4 digit) to be converted to its corresponding age range and have the actual age range, say 18-35, be written to the
emailcollection table in a way that promotes data integrity. I want this to occur every single time without doing a JOIN query. Maybe all I should do is check the value received from the form in PHP and then change that number to the age range I want to see in the database (I care nothing for the 0-4 digit), accomplishing all of this without the need for a 2nd table, and doing everything in PHP before anything is written to the database.