We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Minimal example:
function opf($tpl_output, Smarty_Internal_Template $template) { echo '<pre>'; var_dump(htmlentities($tpl_output)); echo '</pre>'; return $tpl_output . '<br>Text from filter'; } $smarty = new Smarty(); $smarty->setCompileDir('/tmp/smarty/compile'); $smarty->setCacheDir('/tmp/smarty/cache'); $smarty->setCaching(true); $smarty->setTemplateDir('/tmp/smarty/tpl'); $smarty->registerFilter('output', 'opf'); $smarty->display('test.tpl');
test.tpl:
{include file=test2.tpl}
test2.tpl:
{nocache} <p>Timestamp: {$smarty.now}</p> {/nocache}
In Smarty 3.1.27 (or without caching) the $tpl_output variable in the output filter function would be something like
<p>Timestamp: 1452604029</p>
In 3.1.29 (and possibly .28) with enabled cache it is instead
<p>Timestamp: <?php echo time();?></p>
I think it's because of Smarty_Internal_Runtime_UpdateCache::removeNoCacheHash() but did not investigate further.
The text was updated successfully, but these errors were encountered:
- bugfix output filters did not observe nocache code flag #160
04d9c5c
The bugfix is now in the master branch and will later be included in 3.1.30
Sorry, something went wrong.
No branches or pull requests
Minimal example:
test.tpl:
test2.tpl:
In Smarty 3.1.27 (or without caching) the $tpl_output variable in the output filter function would be something like
In 3.1.29 (and possibly .28) with enabled cache it is instead
I think it's because of Smarty_Internal_Runtime_UpdateCache::removeNoCacheHash() but did not investigate further.
The text was updated successfully, but these errors were encountered: