After updating to a new version of Xubuntu 19.10, I am getting an error
Parse error: syntax error, unexpected ':', expecting ';' or '{' in /usr/share/php/Twig/ExtensionSet.php on line 70
when trying to connect to phpmyadmin. It works fine when I switch to php7.3 but I get this error message when using php5.6.
I need to use php5.6 for my older projects.
I tried to reinstall apache2, php and phpmyadmin. Nothing seemed to work.
It's not clear which phpMyAdmin version you're using or from where you've acquired it, but the description makes it clear that you've encountered a version compatibility problem. You are trying to use a phpMyAdmin version that is not compatible with the PHP version you're running. I suggest running phpMyAdmin 4.9.x, which is currently in long-term security support phase (where it gets important security fixes, but is no longer getting day-to-day bugfixes). Version 4.9.x supports PHP version 5.6 no problem.
As Williams suggests, you can use the phpMyAdmin repository (sudo add-apt-repository ppa:phpmyadmin/ppa) to keep up to date.
Related
I did something stupid and while in the middle of a valet use 7.1 process, I pressed ctrl-C. In an attempt to get everything working since then I uninstalled valet+, did a composer global update, a brew update, valet fix, and valet install yet still every site I visit just spits out "Fatal error: Call to undefined function apcu_fetch() in /Users/n8klatt/.composer/vendor/weprovide/valet-plus/server.php on line 37". Any ideas on how I can get Valet+ working again?
(The initial error after interrupting the valet use 7.1 call was "Unable to determine linked PHP", which I remedied with a brew link --force php#5.6 since 5.6 was what I had been using. That allowed me to proceed with the valet use 7.1 but then all my sites started throwing that apcu_fetch error.)
So you're experiencing 2 problems here:
Call to undefined function apcu_fetch() is most likely caused by having PHP-FPM run your webserver on a different PHP version as your CLI. Makes sure your webserver is running the same version as your CLI. An easy was to check this is adding the PHPINFO within the server.php file and check the result. Often restarting your PC allows old PHP-FPM instances to die.
Unable to determine linked PHP is an error thrown when you're running on a native PHP version which is not installed by brew. In this case valet-plus cannot find the correct version number of your PHP installation and throws this error.
Solutions:
Make sure APCu is installed correctly as mentioned in weprovide/valet-plus#133
Make sure your PHP installation is not faulty as mentioned in weprovide/valet-plus#127
Hope that helps, if not give me a comment.
I had the same problem with php56. But I'm not using valet, after I reinstall the PHP56 with brew, and it added pear and pecl module. I installed apcu (couldn't install apc directly) with pecl channel-update pecl.php.net and pecl install apcu-4.0.11.
After that installation added extension="apcu.so" in php56 .ini file, which points to /usr/local/Cellar/php#5.6/5.6.38/lib/php/20131226/apcu.so where the image does not exist really because it was installed by PECL, so I had to change php56 .ini to apcu extension to match extension=/usr/local/lib/php/pecl/20131226/apcu.so where the image file resides for real, and then restart apache and it works.
We are trying to upgrade the database from 2.8.1 to 2.9.0, while doing so thru' SQL Packager tool we get error: Database version '2.8.2' not supported. Am quite new to it and not sure how to resolve this and where to get more details from. The tool was working fine till now for lower versions. Any leads in resolving this is much appreciated!!
The mentioned issue is resolved. It was due to presence of older version of scripts.
I've upgraded to the current version of macOS. I want to work with Apache. Well, my problem is, that when I try to access localhost with or without ~Username, I get an error message saying ERR_CONNECTION_REFUSED on Chrome or "Can't open Page" on Safari. Apache is running and apachectl configtest says "Syntax OK".
I placed the current version of phpMyAdmin into /Library/WebServer/Documents and tried to access it, same problem.
I followed the steps in this guide without a solution for me
Apache localhost/~username/ not working
So does anyone know what problem I'm facing? I'm clueless right now.
I had the same outcomes as above, using virtual hosts though, and after updating to macos 10.12.2 was receiving ERR_CONNECTION_REFUSED.
My original setup is based on the excellent posts here: https://getgrav.org/blog/macos-sierra-apache-mysql-vhost-apc
And as such, because I'm using Homebrew, all I needed to do was also run brew upgrade on CLI followed by sudo apachectl restart and I'm back up and running.
My moodle website corrupted suddenly with this error:
PHP Parse error: syntax error, unexpected T_USE, expecting T_FUNCTION in /admin/tool/log/store/standard/classes/log/store.php on line 30
What can I do?
Thanks
Current PHP version: 5.6
Have you tried downloading the latest version of Moodle from http://download.moodle.org ? (Or updating via Git https://docs.moodle.org/en/Git_for_Administrators )
Whether this is a bug in the exact version of Moodle you are using or a file that has been changed on your server for some reason, an update to the latest version is likely to fix it.
I need to install PHP 5.1.6, MySQL 5.0.95 and Apache/2.2.3 on my computer. Where could I get these versions? I tried to install Apache 2.3.3 on Wamp. Problem is it install but it doesn't want to run with PHP 5.1.6. When I try to select PHP 5.1.6 version I get the following message:
This version doesn't seem to be compatible with your actual Apache version.
What can I do to make it work? Thank you
Why not trying to install them separately ?
Apache 2.2.22 (can't find the 2.2.3): http://mirror.mkhelif.fr/apache//httpd/binaries/win32/
PHP 5.1.6: http://museum.php.net/php5/
MySQL 5.0.96 (can't find the 95): http://dev.mysql.com/downloads/mysql/5.0.html
I found out that it is problem combining that PHP version with that Apache version on Windows OS. I've solve the problem by using Apache 2.0.x