PHP - How do i get an option to be recognized as a number?

Jordan K

New member
Hi, to put it in simple terms, i've created a form with 10 options and each has a drop down box where they can select various foods for each option, so let's say they choose these products e.g

Option 1 - Carrots
Option 2 - Potatoes
Option 3 - Leeks
Option 4 - Peas
Option 5 - Beans

and then they click calculate and it will come up with the total cost.
So how do i get the form to recognize the products as costs?
Would i need to declare this at the start of the code?

Carrots = 30
Peas = 50

Hope you can help, thank you!
x
 
Jordan I'm afraid that I'll need you to elaborate a tad bit more
on what you're looking for. If you could email me some further
details I'm sure that I'll be more than able to assist you.
 
Back
Top