On Friday, March 29, 2002, at 11:39 PM, Jonathan Duncan wrote:
> I have read the page for eval on php.net > several times as well as the very helpful examples, but whenever I use > eval, > it just prints out the same stuff. By same stuff I mean wether I use > eval > or just the variable by itself it just prints out the contents of the > variable. In the web page source it looks as if the contents were > merely > echoed because it still has the $'s and variable names. Any other > ideas or > examples on how to implement eval on this? eval() can let your variable contain PHP code in addition to simple text or HTML. That's what makes it different from just "echoing back the text". So you could do $print_statement = "print('test');"; eval($print_statement); // the output is "test", not "print('test');" I just learned this function myself. HTH, Erik ---- Erik Price Web Developer Temp Media Lab, H.H. Brown [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php