We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Evaluating PHP

Development and Programming

Michael Hay's avatar
Michael Hay
65 posts
16 years ago
Michael Hay's avatar Michael Hay

I have developed a module and part of it includes parsing templates in the backend. I am having trouble evaluating the PHP within templates. I have the following code which I thought would do the trick but I’m not getting anywhere:

global $FNS;
ob_start();
echo $FNS->evaluate($str);    
$str = ob_get_contents();
ob_end_clean();

Can anyone point me in the right direction? I’m using EE 1.6.7 and PHP 5.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.