Hi guys,
this is my first post so be gentle
I have a string of ingredients, eg
1kg of salf
20kg of sugar
15kg of something nice
This is the portion / mix for 1 person, I would like to make it scalable, so for example multiple all ingredients by for two people etc.
So how do I do this with PHP
I am guessing a regexp to look at the string and modify each number by the multiplier
Any suggestions would be great thanks guys
I have tried google and came up empty
I think I need to convert the string to an array then modify it?
John