velden wrote:IIRC {php} tag is nog supported (anymore) in cmsms
Not only that:
http://www.smarty.net/docs/en/language.function.php.tpl
IMPORTANT NOTICE
{php} tags are deprecated from Smarty, and should not be used. Put your PHP logic in PHP scripts or plugin functions instead.
Note
As of Smarty 3.1 the {php} tags are only available from SmartyBC.
You'll have problems upgrading either CMSMS or Smarty anytime in the future.
Besides, it was always considered bad practice to mix logic and design which led to Smarty abandoning that function.
Having said that, I didn't tested it my self but I presume that you would need to get the Smarty object on top of every template. On the 1st {php} block of every template try:
Code: Select all
{php}
$smarty = cmsms()->GetSmarty();
.....
....
Nevertheless, converting all {php} blocks to UDT's should be in the horizon. Any upgrade to either CMSMS or Smarty (or both as a CMSMS release may have the most recent Smarty lib tied to it) may easily break the site.
HTH