Convert or parse a string containing feet and Inches to number in PHP
In my database, there is a field called height that is a varchar(9) field. The end user selects a value from a pull-down list that contains values such as:
5' 0 1/2
5' 1 1/2
5' 2 1/2
And so on up to...
What I need to do is convert this string into numeric inches for the purpose of a server-side calculation. I don't know how to approach this string conversion, so any assistance will be very much appreciated. Thank you!