Skip to content
New issue

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

Incorrect error displayed when there is an error inside of a capture block #1102

Open
moseslecce opened this issue Feb 11, 2025 · 0 comments

Comments

@moseslecce
Copy link

moseslecce commented Feb 11, 2025

When you have an error inside a {capture} block, smarty will incorrectly report that there is a syntax error
"Not matching {capture}{/capture} "

Here is an example of code that would produce this error:

<?php
use Smarty\Smarty;
$smarty = new Smarty();
$template = '{$nullVariable = null} {capture} stuff to capture {$nullVariable->someFunction()} {/capture}';
$smarty->display('eval:'.$template);
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant