Hi,
I'm reasonably new to PHP (but not to coding) and have been having a nightmare trying to get sessions working. My ISP has set up it up and I cannot change it - they don't seem to be helping. I don't know if it's them, me or just a problem with PHP !
Anyway, I'm attempting to write my own session handling routines to get around the problem and get some practice.
One question I have is can PHP produce self modifying code. Ideally I want to interpret a string as PHP code and get it to run. I've manged work out the variable variables bit, and I know some other languages support it. Any idea of how to do it - I'd rather not write a file and then incude it if at all possible.
The sort of thing I'm looking for is:
$b = "varname";
$a = "global " . "$" . "varname;";
interpret $a;
which would have the same affect as:
global $varname;
Thanks,
Nick.