DArnaez Posted February 18 Share Posted February 18 Hi guys. Ok this is what it happen. Trying to resolve a problem with aparently my current theme... and waiting to the vendor contact me for support. I decided to update my Prestashop to 1.8. I did a research and the best way was using the 1ClickUpdate... so I proceed to that but at the end of the process it stop and show this message: [INTERNAL] /xxxxx/xxxxxx/mysite.com/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php line 70 - Declaration of Doctrine\DBAL\Driver\PDOConnection::query() must be compatible with PDO::query(string $query, ?int $fetchMode = null, mixed ...$fetchModeArgs): PDOStatement|false I can access the file using ftp but I have no idea what to change. After that I receive a blank page. No access even to the Admin. So I edited defines.inc.php file, and find the line define('_PS_MODE_DEV_', false); - change "false" to "true". But now... trying to acces the admin it shows: (1/1) FatalErrorException Compile Error: Declaration of Doctrine\DBAL\Driver\PDOConnection::query() must be compatible with PDO::query(string $query, ?int $fetchMode = null, mixed ...$fetchModeArgs): PDOStatement|false in PDOConnection.php line 70 Link to comment Share on other sites More sharing options...
ComGrafPL Posted February 18 Share Posted February 18 Have you tried to change PHP version to i.e 8.1? also clear cache in VAR? Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 Hi Thanks a lot for to reply! I'm have zero experience in coding. My big mistake was to trust in all other times that I upgrade and the process was fine. so now I did't use the backup options. No I didn't try the 8.1 version but if you say is better, please let me know where I download it. 2) What should I do to clear the cache in VAR? I only have access to file manager from the hosting. Here is the screen previous to update (for some reason I have the tab opened in the browser but if I refresh will turn blank. Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 (edited) Ok In /var/cache I see two folders dev and prod. Should I delete both or just the content inside? In meanwhile I'm downloading the file to my PC. Edited February 18 by DArnaez (see edit history) Link to comment Share on other sites More sharing options...
ComGrafPL Posted February 18 Share Posted February 18 (edited) On 2/18/2025 at 7:14 PM, DArnaez said: Ok In /var/cache I see two folders dev and prod. Should I delete both or just the content inside? Expand Edit: So you did not yet update to prestashop new version? Error in on updating process? Edited February 18 by ComGrafPL (see edit history) Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 (edited) Ohh!...I'm using PHP 8.2 (ea-php82) Ok Cache renamed.... and created a new cache folder Edited February 18 by DArnaez (see edit history) Link to comment Share on other sites More sharing options...
ComGrafPL Posted February 18 Share Posted February 18 On 2/18/2025 at 7:31 PM, DArnaez said: Ohh!...I'm using PHP 8.2 (ea-php82) Expand If upgrade was failed. Use PHP 7.4 / 7.3. Clear cache and try with back office access. Do you have any backup to restore it? Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 Still... don't let me in the admin. FatalErrorException Compile Error: Declaration of Doctrine\DBAL\Driver\PDOConnection::query() must be compatible with PDO::query(string $query, ?int $fetchMode = null, mixed ...$fetchModeArgs): PDOStatement|false Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 Hostgator hosting only give me these PHP versions PHP 8.1 - PHP 8.2 or PHP 8.3 Link to comment Share on other sites More sharing options...
ComGrafPL Posted February 18 Share Posted February 18 (edited) On 2/18/2025 at 8:20 PM, DArnaez said: Hostgator hosting only give me these PHP versions PHP 8.1 - PHP 8.2 or PHP 8.3 Expand Any option there to restore the backup? Edited February 18 by ComGrafPL (see edit history) Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 Auch... So my only solution is to pay ( hostgator charge me $50 for restore from backup) to restore to 5 days ago. IDK... this site is my only one using Prestashop. I'm considering seriusly to migrate to WooCommerce. Is a shame. Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 Wait I see Prestashop 8 recommend PHP 8.1 https://devdocs.prestashop-project.org/8/basics/installation/system-requirements/ Link to comment Share on other sites More sharing options...
Nickz Posted February 18 Share Posted February 18 If the host gives you issues why would you change the shop? Change the hoster. Learn hao to restore shops yourself. A shop can be fairly easy installed into localhost. There is the place to play with it. 1 Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 Now that I see... Prestashop jump from Prestashop 1.7.x to 1. Prestashop 8? Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 On 2/18/2025 at 8:25 PM, ComGrafPL said: Any option there to restore the backup? Expand I don't have a backup. Hostgator charge you if you want to use a backup. Link to comment Share on other sites More sharing options...
DArnaez Posted February 18 Author Share Posted February 18 So... I want to update to PS 8 but my attempt to Update... Can I install Prestashop 8.2 from the script (Hostgator have a script on cpanel) over my current Prestashop 1.7.8.6? Link to comment Share on other sites More sharing options...
Nickz Posted February 18 Share Posted February 18 On 2/18/2025 at 9:34 PM, DArnaez said: I don't have a backup. Hostgator charge you if you want to use a backup. Expand What are you paying for that service? Yearly? What Specs do they give you? Link to comment Share on other sites More sharing options...
DArnaez Posted February 19 Author Share Posted February 19 No I wasn't paying. Years ago it was free... Now they make you buy CodeGuard service... that it cover for a year. I create a ticket to see if they can recover from a week before. Link to comment Share on other sites More sharing options...
DArnaez Posted February 19 Author Share Posted February 19 Ok... Finally I paid to the hosting provider (Hostgator) to recover the site... after claims, backs and forwards... I have the website back... with errors again. If you choose any product you will see: (1/1) ContextErrorException User Notice: escape: unsupported type: html_attr - returning unmodified string in modifier.escape.php line 257 This is how all the problem start. Can you guide me to upgrade to PS 8 please? Link to comment Share on other sites More sharing options...
Mediacom87 Posted February 20 Share Posted February 20 On 2/19/2025 at 10:39 PM, DArnaez said: This is how all the problem start. Can you guide me to upgrade to PS 8 please? Expand First, you need to use the right version of PHP for your 1.7 PrestaShop version. After, that, if all it'zs ok, you need to make a complete backup of your site (files and data). And after that, you can test an upgrade on one copy of your site because it's important to test it on another installation not on your prod site. If your hosting service doesn't give you access to the PHP 7 version, you have to change to a good hosting service, with free backup solution too. Link to comment Share on other sites More sharing options...
DArnaez Posted February 20 Author Share Posted February 20 OK I understand... Hostgator only have PHP 8.1, 8.2, 8.3 and Inherit (no idea what is that). Do you recommend another Hosting provider? The problem is that how can I know before to buy what PHP version are usig? Maybe I should update to Prestashop 1.8 instead. I looking for any developer to help me with that. Link to comment Share on other sites More sharing options...
DArnaez Posted February 20 Author Share Posted February 20 (edited) OK is very confuse. In hostgator, it show the version of PHP in my domain is PHP 8.1 . But Prestashop it show is running PHP 7.4.33. Edited February 20 by DArnaez (see edit history) Link to comment Share on other sites More sharing options...
DArnaez Posted February 20 Author Share Posted February 20 Trying to upgrade using 1-Click Upgrade it finish "THe setting have been successfully updated" But in ERRORS section it shows: [INTERNAL] /..../xxxxxx/mydomain.com/src/PrestaShopBundle/DependencyInjection/RuntimeConstEnvVarProcessor.php line 39 - Symfony\Component\DependencyInjection\Exception\EnvNotFoundException: Environment variable not found: "runtime:_PS_ALLOW_MULTI_STATEMENTS_QUERIES_". #0 /..../xxxxxx/mydomain.com/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/Container.php(491): PrestaShopBundle\DependencyInjection\RuntimeConstEnvVarProcessor->getEnv('const', 'runtime:_PS_ALL...', Object(Closure)) #1 /..../xxxxxx/mydomain.com/var/cache/dev/ContainerE3rt2y6/appDevDebugProjectContainer.php(2981): Symfony\Component\DependencyInjection\Container->getEnv('const:runtime:_...') #2 /..../xxxxxx/mydomain.com/var/cache/dev/ContainerE3rt2y6/appDevDebugProjectContainer.php(3023): ContainerE3rt2y6\appDevDebugProjectContainer->getDoctrine_Dbal_DefaultConnectionService() #3 /..../xxxxxx/mydomain.com/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/Container.php(306): ContainerE3rt2y6\appDevDebugProjectContainer->getDoctrine_Orm_DefaultEntityManagerService() #4 /..../xxxxxx/mydomain.com/vendor/symfony/symfony/src/Symfony/Bridge/Doctrine/ManagerRegistry.php(63): Symfony\Component\DependencyInjection\Container->get('doctrine.orm.de...') #5 /..../xxxxxx/mydomain.com/vendor/doctrine/persistence/lib/Doctrine/Persistence/AbstractManagerRegistry.php(204): Symfony\Bridge\Doctrine\ManagerRegistry->getService('doctrine.orm.de...') #6 /..../xxxxxx/mydomain.com/vendor/symfony/symfony/src/Symfony/Bridge/Doctrine/CacheWarmer/ProxyCacheWarmer.php(53): Doctrine\Persistence\AbstractManagerRegistry->getManagers() #7 /..../xxxxxx/mydomain.com/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/CacheWarmer/CacheWarmerAggregate.php(52): Symfony\Bridge\Doctrine\CacheWarmer\ProxyCacheWarmer->warmUp('/xxxxx/xxxxxxx...') #8 /..../xxxxxx/mydomain.com/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php(686): Symfony\Component\HttpKernel\CacheWarmer\CacheWarmerAggregate->warmUp('/xxxx/xxxxxx...') #9 /..../xxxxxx/mydomain.com/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php(135): Symfony\Component\HttpKernel\Kernel->initializeContainer() #10 /..../xxxxxx/mydomain.com/modules/autoupgrade/classes/UpgradeTools/SymfonyAdapter.php(67): Symfony\Component\HttpKernel\Kernel->boot() #11 /..../xxxxxx/mydomain.com/modules/autoupgrade/classes/UpgradeTools/CoreUpgrader/CoreUpgrader17.php(43): PrestaShop\Module\AutoUpgrade\UpgradeTools\SymfonyAdapter->initKernel() #12 /..../xxxxxx/mydomain.com/modules/autoupgrade/classes/UpgradeTools/CoreUpgrader/CoreUpgrader.php(102): PrestaShop\Module\AutoUpgrade\UpgradeTools\CoreUpgrader\CoreUpgrader17->initConstants() #13 /..../xxxxxx/mydomain.com/modules/autoupgrade/classes/Task/Upgrade/UpgradeDb.php(49): PrestaShop\Module\AutoUpgrade\UpgradeTools\CoreUpgrader\CoreUpgrader->doUpgrade() #14 /..../xxxxxx/mydomain.com/modules/autoupgrade/classes/Task/Runner/ChainedTasks.php(61): PrestaShop\Module\AutoUpgrade\Task\Upgrade\UpgradeDb->run() #15 /..../xxxxxx/mydomain.com/admin/autoupgrade/ajax-upgradetab.php(54): PrestaShop\Module\AutoUpgrade\Task\Runner\ChainedTasks->run() #16 {main} Link to comment Share on other sites More sharing options...
Nickz Posted February 20 Share Posted February 20 Something like this? https://github.com/PrestaShop/PrestaShop/issues/14068 Hostgator specs do you have those? Where do your clients come from we need to know before giving out hosting tips. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now