Eval() function
Eval () is used to evaluate the input string as PHP. It is like using the Echo() function in the sense that it outputs everything, except instead of outputting it as text, it outputs it as PHP code to be executed. One use of this is to store code in a database to execute later.
Example :
<?php
$name1 = ‘User1′;
$name2 = ‘User2′;
$a = ‘Welcome $name1,$name2′;
print $a . “<br>”;
eval(”\$a = \”$a\”;”);
print $a . “<br>”;
?>
