plugin content_dump send error in smarty 3

The place to talk about things that are related to CMS Made simple, but don't fit anywhere else.
Post Reply
uloloi
Forum Members
Forum Members
Posts: 88
Joined: Thu Dec 16, 2010 8:50 pm

plugin content_dump send error in smarty 3

Post by uloloi »

Hi, I like to use content_dump so much!

But in CMSMS 11.1.+, well, with the use of smarty 3 the source generates an error becuase the use of _compile_source is mmm... deprecated?

How can I solve this line in the source of the plugin, I can't find the solution in the manual of smarty. How to compile source with smarty 3? :S

Error: at line 806 in file mysite\lib\smarty\sysplugins\smarty_internal_templatebase.php:

Call of unknown method '_compile_source'.



It is generated when I use content_dump optiion do_smarty( param:compile ...)

Code: Select all

$smarty->_compile_source('temporary template', $content_dump[$i]->content->data, $_compiled);			
psy
Power Poster
Power Poster
Posts: 463
Joined: Sat Jan 22, 2005 11:19 am

Re: plugin content_dump send error in smarty 3

Post by psy »

See Calguy's post about the Smarty3 way of compiling:
http://forum.cmsmadesimple.org/viewtopi ... 75#p284375

To echo the output:

Code: Select all

$smarty->display('string:'. $mysmartydata);
To save the ouput for later use:

Code: Select all

$myvar = $smarty->fetch('string:'.$mysmartydata);
More info of course in the Smarty docs.
Post Reply

Return to “The Lounge”