In fact, if you don't need the old values, then you could simplify even further. The text of the option (between the <OPTION> </option> tags) will become the default value if you don't specify a value inside <OPTION Value="HERE">.
what if hoachen didn't want to change the value of those options?
- if that the case, then you can use regular expression method or str_replace to take out just the name of the file without the extension; then make the name with all capital letters; finally, concatinate it with the word "FOOD" --> and send to your email
orbitz is right I don't want to put value "option value=" here" is because, when i click on the selection it will bring me to another page. Yes, I only want it to send to my mail box not to echo. Orbitz, you suggested to put reg to trim it off but where(which part) i should do the reg? any suggestion?
I try it this way
$food = ._$POST['food'];
$new_food = ereg_replace("../food/*.htm", I don't know how to put here, $food));
I just want to replace the "../food/.htm" where the *astrick is what i want to print it on my mailbox.
fyrestrtr, first thank you for your code, I try it and it didnt work. I don't want to echo anything and don't really understand what is "strtoupper(basename" Well, I will check it on the web later.