Jump to content

Modules page is not loading in Backoffice


astathopoulos

Recommended Posts

I am using Prestashop 1.6.1.15 and after upgrading from 1.6.1.14, the AdminModules page is not loading with the following error:

Installed modules [PrestaShop] Fatal error in module file
:<path_to_prestashop_installation>/tools/smarty/plugins/modifier.replace.php:
Uncaught Error: Call to undefined function $() in
<path_to_prestashop_installation>/tools/smarty/plugins/modifier.replace.php:30
Stack trace: #0
<path_to_prestashop_installation>/cache/smarty/compile/ec/47/7d/ec477da7766c729d5ca0efb768279dc04c80cc65.file.kpi.tpl.php(62): �('90', '&', '&') #1 <path_to_prestashop_installation>/tools/smarty/sysplugins/smarty_internal_templatebase.php(188): content_5975e89bb6b303_94225905(Object(Smarty_Custom_Template)) #2 <path_to_prestashop_installation>/classes/SmartyCustom.php(317): Smarty_Internal_TemplateBase->fetch(Object(Smarty_Custom_Template), NULL, NULL, NULL, false, true, false) #3 <path_to_prestashop_installation>/classes/helper/HelperKpi.php(63): Smarty_Custom_Template->fetch() #4 <path_to_prestashop_installation>/controllers/admin/AdminModulesController.php(1315): HelperKpiCore->generate() #5 <path_to_prestashop_installation>/controllers/admin/AdminModulesController.php(1)

When I disable Caching and I choose "Force compilation" the error message is the following:

[PrestaShop] Fatal error in module file :<path_to_prestashop_installation>/classes/ConfigurationKPI.php:
Uncaught Error: Call to undefined method ConfigurationKPI::ace","author":"Malttt","image":"..\/img\/tmp\/a9f143a4c9899aab5cc2dde714ab7557.jpg","option":""}, {"displayName":"Google AdWords","desc":"Show your ad to people at the very moment they are searching for what you offer","name":"gadwords","author":"PrestaShop Partners","image":"..\/img\/tmp\/74655e386c71fd901da39083fd6288fe.jpg","option":""}, {"displayName":"Google Analytics","desc":"\u0391\u03c0\u03bf\u03ba\u03c4\u03ae\u03c3\u03c4\u03b5 \u03be\u03b5\u03ba\u03ac\u03b8\u03b1\u03c1\u03b5\u03c2 \u03c0\u03bb\u03b7\u03c1\u03bf\u03c6\u03bf\u03c1\u03af\u03b5\u03c2 \u03bc\u03ad\u03c3\u03c9 \u03c3\u03b7\u03bc\u03b1\u03bd\u03c4\u03b9\u03ba\u03ce\u03bd \u03bc\u03b5\u03c4\u03c1\u03ae\u03c3\u03b5\u03c9\u03bd \u03b3\u03b9\u03b1 \u03c4\u03bf\u03c5\u03c2 \u03c0\u03b5\u03bb\u03ac\u03c4\u03b5\u03c2 \u03c3\u03b1\u03c2, \u03c7\u03c1\u03b7\u03c3\u03b9\u03bc\u03bf\u03c0\u03bf\u03b9\u03ce\u03bd\u03c4\u03b1\u03c2 \u03c4\u03b1 Google Analytics","name":"ganalytics","author":"Pre

The module that is trying to "parse" is https://addons.prestashop.com/en/registration-ordering-process/24894-google-address-autocomplete.html and I found that it exists in the `must_have_modules_list.xml` config file.

 

I don't think that this has to do with the upgrade, but I really don't know where to start looking what is wrong.

 

Any ideas?

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

Apparently, this error occurs only with PHP 7.0.21. When I switch to 5.6.31 everything works fine. I have the same installation locally (same modules folders, same database) with PHP 7.0.19 and it also works.

 

I am starting to believe that something changed from 7.0.19 to 7.0.21 that broke smarty.

 

The release of 7.0.21 (06 Jul 2017) perfectly fits the period that I noticed that this page started to blow up (Siteground is really fast at bringing the latest PHP minor versions to its plans).

 

I have to investigate it more I guess.

Link to comment
Share on other sites

  • 2 weeks later...

Hi pesu,

 

I didn't have time to further investigate it. I have to install PHP 7.0.21 locally to figure out what is happening. What I have done as a dirty hack is to switch temporarily the admin section to PHP 5.6.31.

 

I will post here, if I have any update!

  • Like 1
Link to comment
Share on other sites

Just for information - we run 1.6.1.15 instances with PHP 7.0.20 without any problems in this context.

The function called on line 30 in the smarty files is:

    return smarty_mb_str_replace($search, $replace, $string);

But why does it say: Call to undefined function $() ?

Edited by Scully (see edit history)
  • Like 1
Link to comment
Share on other sites

I have 8 shops they all uses 1.6.1.15 and PHP 7.0.21. But only one has the problem and it occured after I installed a module manually. It's very strange.

I will update to 1.6.1.16 tomorrow and see what happens after the update.

Link to comment
Share on other sites

I just switched admin back to PHP7.0. At the following error occured:

[PrestaShop] Fatal error in module file :/home/astathop/public_html/pharmacynextdoor.gr/Adapter/Adapter_Configuration.php:
Interface 'Core_Business_ConfigurationInterface' not found

But after the refresh everything worked again.

 

I have upgraded prestashop to 1.6.1.16 but I don't think that this is fixed the problem. Another thing that was changed is that Siteground upgraded its PHP version to 7.0.22.

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...