Prestashop PHP 7: Fix error while saving preferences

PHP 7 makes powering your Prestashop website a whole lot better and run very fast for deployment on a server with PHP5. Unfortunately, there are some small errors with Prestashop PHP 7. This tutorial will show you how to fix the error when save preferences in BO.

Prestashop PHP 7: Fix error while saving preferences

PHP7 or PHP5 ?

It's a simple question. PHP7 is faster than PHP5 and at the same level with HHVM ( HHVM is an open-source virtual machine designed for executing programs written in Hack and PHP, a son of Facebook team). Here are some benchmark between PHP7, HHVM and PHP5:

PHP7 vs HHVM on Wordpress 4.4

PHP7 vs HHVM on Wordpress 4.4

PHP7 vs PHP 5.6 vs HHVM on Drupal 8.0.1

PHP7 vs PHP 5.6 vs HHVM on Drupal 8.0.1

PHP7 vs PHP 5.6 vs HHVM on Magento 2.0 CE

PHP7 vs PHP 5.6 vs HHVM on Magento 2.0 CE

Prestashop not fully support PHP7 - that's why we don't have the benchmark on Prestashop. However, you can be sure that with PHP7, your Prestashop site will run very fast.

Prestashop PHP 7: Fix the error

When you try to customize your website's preferences, you will get the following errors on many screens:

PHP Fatal error:  Uncaught Error: Access to undeclared static property: Validate::$values in /your-root-folder/classes/controller/AdminController.php:1389

We need to open the above file and replace all of this type :

Validate::$values['property']

by

Validate::{$values['property']}

Your problem will be fixed and you could depoy a Prestashop website on PHP7.

Halloween theme

PrestaSEO AI++.

PrestaSEO AI module

PrestaSEO AI++ is a cutting-edge module designed to take your PrestaShop store’s SEO to the next level. Built with advanced automation and AI technology, it streamlines SEO tasks, making optimization easier and more effective.

Whether you're focused on improving local visibility or cleaning up your site's URL structure, PrestaSEO AI provides a comprehensive suite of features to enhance your store's performance.

Latest modules update!

iConvert Promotions 8.0.0 ⊙

Optimize source codes to improve the performance and user experiences on PrestaShop 8, resolved various issues to enhance compatibility with PrestaShop 1.7.x.


DocumenThemix 3.3.7 ⊙

Compatible with PrestaShop 8.


ChargeMe v5.4.1 ⊙

Clear the cart & redirect to the checkout page.


Age Restriction - 18+ v2.3.6⊙

Fix page assignment issues.


Newsletter Popup v3.2.5 ⊙

Enhance the level of security.


JumptoCheckout v.2.1.1 ⊙

Fix the deleting product issue.


PrestaSOO team

Trusted by 7k++ clients.

Modules you need to make a living doing work you love.

Discover

It is a wise investment

PrestaShop modules we created first to solve the problem of our own business - an e-Commerce site. That means they are very useful for serious business. If you value your web property, these modules are a wise investment.
Sarah Reeves, App Developer @ PrestaSOO
Made with in Paris & Hanoi
PrestaSOO © 2024. All rights reserved. // Privacy Policy Terms of Service