I have three form fields in a form that have values like the following:
$field1="Glass";
$field2="Plastic";
$field3="Metal";
There would be many more values that could be entered. But, what I want to do is once the form is submitted, convert the field value into a preset two-letter combo.
Like:
Glass change to "GL"
Plastic change to "PL"
etc. Then put the results back into variables.
like
NewField="GL";
NewField2="PL";
type deal.
I hope that makes sense. Anyone know how I can do that, without doing an
if($field1=="Glass"){$NewField="GL";}
for every single combination, for each of three fields?