Jump to content

Fatal error - Smarty


Stel25

Recommended Posts

Hello,

[PrestaShop] Fatal error in module file :/var/www/####/data/www/####/tools/smarty/sysplugins/smarty_internal_templatebase.php(157) : eval()'d code:
syntax error, unexpected '<', expecting end of file

I'm getting a blank page on both my frontend and backend. I have disabled smarty from the database because I dont have access to the backend.
Is there something else I can do? How can I disable completely smarty cache and compile files?

Link to comment
Share on other sites

Thank you,

When I set debug mode to true the same error appears in the frontend.

Is there a way to make smarty not function at all? I think it's from compiling tpl files and error on escaping some characters from a view.

 

Link to comment
Share on other sites

You can open the file in the PHP editor, it will help to show the error line and mark it in red color. It will be helpful in fixing the errors in PHP files

Some web hosting file editors have featured as well to fix PHP error file

Some free editors are netbeans and visual studio code

 

Edited by Zohaib-fk
Post Updated (see edit history)
Link to comment
Share on other sites

Thank you for replying quickly!

Unfortunately this is not the case, i cheched the file and it is ok.

I suppose that this is coming from compiling a tpl file and not escaping characters while trying to compile a js script or smt like that.

Link to comment
Share on other sites

  • 3 weeks later...
On 9/11/2022 at 1:56 PM, Nickz said:

how did it happen? Suddenly out of nowhere?

To me it is happening the same thing, "Parse error: syntax error, unexpected '<', expecting end of file in /home/xxxxxxxxx/www/tools/smarty/sysplugins/smarty_internal_templatebase.php(157) : eval()'d code on line 1"

 

It was out of nowhere, and when i turn the smarty cache OFF its works but only after 10+ times reloading, when i turn smarty cache ON sometimes work but without menu.

imagem.thumb.png.f94506b7b814a090f0b4aa71cab86b1b.png

Link to comment
Share on other sites

  • 1 month later...

Hello,

I'm getting the same error on PS 1.6.1.5

When trying to visit Admin > Modules page:

[PrestaShop] Fatal error in module file :/public_html/tools/smarty/sysplugins/smarty_internal_templatebase.php(157) : eval()'d code:
syntax error, unexpected '<', expecting end of file

On frontend side, the menu is gone. Any help?

 

Edited by Clay7 (see edit history)
Link to comment
Share on other sites

  • 2 months later...
On 10/17/2022 at 3:10 PM, Stel25 said:

Hello,

I 've solved it, you can check the following link.

https://build.prestashop-project.org/news/major-security-vulnerability-on-prestashop-websites

 

 

@Stel25 - what do u mean you solved it?

Link you have posted is info about Presta security - what it has to do with :

[PrestaShop] Fatal error in module file :/public_html/tools/smarty/sysplugins/smarty_internal_templatebase.php(157) : eval()'d code:
syntax error, unexpected '<', expecting end of file

Are u sugesting that error means that site was attacked using that vulnerability?

Can u be more clear about it pls

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...