0
Not a bug

PHP Fatal error: Uncaught --> Smarty Compiler: Syntax error in template

mrklugmrklug 2 months ago updated by Vlad R 1 month ago 11

Hey, I've never had any real problems. But now all of a sudden, for example, I couldn't really log out anymore. If I wanted to do this I just came to a white page https://domain /?module=fileman&page=logout when I wanted to go back to my login page, I was still logged in. If I want to share a folder, it only says Loading...... when I close the window, a link was created exactly the same when I try to delete it, it is just loading again and when I close the window, the link was removed.

In the Apache2 PHP Log:
[Sat Dec 10 15:58:38.903325 2022] [php7:error] [pid 1937] [client ip] PHP Fatal error: Uncaught --> Smarty Compiler: Syntax error in template "string:" - Unexpected ": ", expected one of: "}" <-- \n thrown in /var/www/domain/system/classes/smarty/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 196, referer: https://domain/
[Sat Dec 10 15:58:40.129446 2022] [php7:error] [pid 1949] [client ip] PHP Fatal error: Uncaught --> Smarty Compiler: Syntax error in template "string:" - Unexpected ": ", expected one of: "}" <-- \n thrown in /var/www/domain/system/classes/smarty/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 196, referer: https://domain/
[Sat Dec 10 15:58:40.685833 2022] [php7:error] [pid 1936] [client ip] PHP Fatal error: Uncaught --> Smarty Compiler: Syntax error in template "string:" - Unexpected ": ", expected one of: "}" <-- \n thrown in /var/www/domain/system/classes/smarty/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 196, referer: https://domain/
[Sat Dec 10 16:00:03.792307 2022] [php7:error] [pid 1937] [client ip] PHP Fatal error: Uncaught --> Smarty Compiler: Syntax error in template "string:" - Unexpected ": ", expected one of: "}" <-- \n thrown in /var/www/domain/system/classes/smarty/libs/sysplugins/smarty_internal_templatecompilerbase.php on line 196

There are also other lines I'm not sending the whole file because there are data in there that I don't want to share publicly. but could send the whole file privately or something.

Thank you very much!

Answer

+1
Answer
Not a bug

The e-mail notification template is Smarty-sensitive code: https://www.smarty.net/docsv2/en/language.escaping.tpl

Under review

My recommendation is to download the installation package (https://filerun.com/download-latest) and replace the folder "system/modules" from your existing installation with the one from the package. To make sure there is no wrongly customized/edited/corrupted file in your installation. This of course assumes you are running the latest FileRun version.

Let me know how it goes after that.

Thank you for the answer. Unfortunately, it did not work is still exactly the same problem.

What I didn't write is when I want to log in this message comes:

Image 1271


If I then click on Sign In again this message comes:

Image 1272


and afterwards I can access the data when I reload the page

Image 1273

Have you manually edited any files inside the FileRun installation?

Yes. I changed in /var/www/filerun/images/favicons the favicons and in /var/www/filerun/customizables the config.php I added the YOURLS Shortener


<?php

$config['app']['weblinks']['custom_url_shortener'] = 'https://s.domain/yourls-api.php?signature=SIGNATURE&action=shorturl&format=simple';

Otherwise I did not change anything manually.

Maybe you left an empty spac or line break outside <?php inside the config.php?

But I have changed this config for quite some time and so far it has always worked the errors came out of nowhere

I haven't even really done anything on my server or the cloud right now.

+1

Do you have any e-mail notfication configured? If you have, and if you disable them (by unchecking the "Instant e-mail notification" option under "E-mail"), does the problem persist?

Thank you so much!
I had inserted an HTML code there everything worked but yesterday I changed something about it was that the problem? Or does it have something to do with the Instant Notification checkbox?

+1
Answer
Not a bug

The e-mail notification template is Smarty-sensitive code: https://www.smarty.net/docsv2/en/language.escaping.tpl

Okay now it's clear why. Thank you very much, it's funny that it only worked with HTML before. Well thank you again.