I have these lines of code.
<select id="select12" name="package">
<option value="0.00">(Select a Package)</option>
<option value="149.00">PACKAGE A</option>
<option value="223.00">PACKAGE B</option>
<option value="273.00">PACKAGE C</option>
</select>
I want to get the "Package A/B/C" and its value. For example if the user selects the Package A. The output is Package A - $149.00. How will I do that? This is the code I have so far in achieving that getting the HTML, but it is no luck.
$package = $_POST['package'];
$email_message = "Form details below.\n\n";
function clean_string($string) {
$bad = array("content-type","bcc:","to:","cc:","href");
return str_replace($bad,"",$string);
}
$email_message .= "Selected Package: ".clean_string($package)."\n";