Menu
Hi.
Does the PHP eval() function work in a similar way the javascript version?
I have the following function:
function altercolour($colour1, $colour2, $colour3) {
}
If the value “green” is given to $colour1, I want to perform alterations to the variable $green, and if “blue” is submitted the function would alter $blue…. etc.
Is this possible with eval(), in a similar way to javascript? Or can anyone suggest a better way to do this?