How can I execute php coding in a string. Because once I replace all variable within my template the string will contain: "<?php if($something) { echo $this; } ?>

So after replacing all variables with values how can I execute the php codes in the string before printing the final result?
Is there a php function for this, because i seem to find it on the php site.

    You could use [man]eval/man, but use it with caution as it could be abused if the string is under the control of the user.

      Write a Reply...