I can't debug PHP script in Visual Studio Code - Linux (Ubuntu 18.04.2 LTS).
Before Update, the Xdebug version I was fettching error such as :
Xdebug requires Zend Engine API version 320170718.
The Zend Engine API version 320160303 which is installed, is outdated.
After an update the Xdebug version now fetching following error:
Error: Failed loading /opt/lampp/lib/php/extensions/no-debug-non-zts-20160303/xdebug.so: /opt/lampp/lib/php/extensions/no-debug-non-zts-20160303/xdebug.so: undefined symbol: zend_empty_string.
This is my PHP status:
php -v
PHP 7.2.17-0ubuntu0.18.04.1 (cli) (built: Apr 18 2019 14:12:38) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
with Zend OPcache v7.2.17-0ubuntu0.18.04.1, Copyright (c) 1999-2018, by Zend Technologies
with Xdebug v2.7.2, Copyright (c) 2002-2019, by Derick Rethans
Please correct me if anything is missing at my end.
I would suggest to use the tailored wizard from the Xdebug website:
Xdebug Wizard
It seems that you are mixing the PHP versions: The Zend Engine API version 20160303 corresponds to PHP 7.1. For 7.2 you will need API version 20170718.
I suppose you have several versions of PHP active - most probably 7.1, 7.2 and 7.3. In such case you need to run the proper phpize - phpize7.2 when going through the wizard.
Related
I am on the Apple M1 arm64 chip arm64.
I am trying to install the ioncube for PHP 7.4
On the ioncube website i download the package above:
Failed loading /opt/homebrew/opt/php#8.0/lib/httpd/modules/ioncube_loader_dar_7.4.so:
dlopen(/opt/homebrew/opt/php#8.0/lib/httpd/modules/ioncube_loader_dar_7.4.so,
0x0009): tried: '/opt/homebrew/opt/php#8.0/lib/httpd/modules/ioncube_loader_dar_7.4.so'
(code signature in <271472A6-19B1-339D-AE94-FD446AED8DB2>
'/opt/homebrew/Cellar/php#8.0/8.0.27/lib/httpd/modules/ioncube_loader_dar_7.4.so'
not valid for use in process: library load disallowed by system policy),
'/opt/homebrew/Cellar/php#8.0/8.0.27/lib/httpd/modules/ioncube_loader_dar_7.4.so'
(code signature in <271472A6-19B1-339D-AE94-FD446AED8DB2>
'/opt/homebrew/Cellar/php#8.0/8.0.27/lib/httpd/modules/ioncube_loader_dar_7.4.so'
not valid for use in process: library load disallowed by system policy
Afterwards i tried macOS (64 bits) version
Cannot load the ionCube PHP Loader - it was built with configuration API320190902,NTS, whereas running engine is API420200930,NTS
PHP 8.0.27 (cli) (built: Jan 12 2023 02:35:14) ( NTS )
Copyright (c) The PHP Group
Zend Engine v4.0.27, Copyright (c) Zend Technologies
with Xdebug v3.2.0, Copyright (c) 2002-2022, by Derick Rethans
with Zend OPcache v8.0.27, Copyright (c), by Zend Technologies
With PHP 7.4 i don't have any problems.
How i can solve the problem in PHP 8.1?
I have a strange problem with Mac OS. Problem mixing two versions.
When I look at the PHP version through the VSCode:
When I look at the PHP version through the terminal:
~ ยป php -v
PHP 8.1.0 (cli) (built: Nov 28 2021 02:36:02) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.1.0, Copyright (c) Zend Technologies
with Zend OPcache v8.1.0, Copyright (c), by Zend Technologies
When I run a page of code in XAMPP containing phpinfo();
PHP Version 8.0.6
This program makes use of the Zend Scripting Language Engine:
Zend Engine v4.0.6, Copyright (c) Zend Technologies
with Xdebug v3.1.1, Copyright (c) 2002-2021, by Derick Rethans
I just want to have PHP installed on my system. What is the solution to my problem?
I was using Linux Mint 18.3 and I upgraded to Linux Mint 19 based on Ubuntu 18.04. My problem is I have a PHP rest api which was built using PHP 7.0.22 and now it's doing weird things.
I've googled for a solution and I found nothing about PHP 7.0.22 on Ubuntu 18.04.
I must say that PHP is unknow for me and I can't tell what I did since I ran a lot of commands, but now if I hit:
$ php -v
it responds:
Failed loading /usr/lib/php/20151012/xdebug.so: /usr/lib/php/20151012/xdebug.so: cannot open shared object file: No such file or directory
PHP 7.0.32-0ubuntu0.16.04.1 (cli) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies
with Zend OPcache v7.0.32-0ubuntu0.16.04.1, Copyright (c) 1999-2017, by Zend Technologies
I went into /usr/lib/php/20151012/ and there is no xdebug.so file. How can I solve this? What am I missing?
I have installed plesk onyx in my ubuntu server plus php v7.0 and v7.1. When I tried to install WHCMS v 7.3.0 he told me that I have old ioncube loeader version and I need to make an upgrade to continue the installation so I followed that tutorial : https://support.plesk.com/hc/en-us/articles/214527125-The-IonCube-loader-is-not-available-for-Plesk-PHP-7-1
and this is the version of php v7.0 and v7.1 :
root#sd-86418:/opt/plesk/php/7.1/lib/php/modules# /opt/plesk/php/7.1/bin/php -v
PHP 7.1.10 (cli) (built: Sep 29 2017 15:42:12) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies
with the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured) v10.0.3, Copyright (c) 2002-2017, by ionCube Ltd.
with Zend OPcache v7.1.10, Copyright (c) 1999-2017, by Zend Technologies
root#sd-86418:/opt/plesk/php/7.1/lib/php/modules# /opt/plesk/php/7.0/bin/php -v
Cannot load the ionCube PHP Loader - it was already loaded
PHP 7.0.24 (cli) (built: Sep 29 2017 12:33:10) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies
with the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured) v10.0.3, Copyright (c) 2002-2017, by ionCube Ltd.
with Zend OPcache v7.0.24, Copyright (c) 1999-2017, by Zend Technologies
The issue is all time I got HTTP ERROR 500. Please any one help me.
Cannot load the ionCube PHP Loader - it was already loaded
In Plesk ioncube module is already installed and loaded out of the box with the corresponding plesk-php70-ioncube-loader package. You shouldn't install it as described in the mentioned KB article.
Actually, it is a bad idea to install WHMCS on the server where Plesk is already installed. Consequences may be unpredictable. Anyway, why do you think that WHMCS installer uses Plesk PHP /opt/plesk/php/7.0/bin/php instead of OS vendor's PHP from /usr/bin/php with own outdated ioncubeloader?
I have lamp server installed in ubuntu OS. And, when I check my php version using phpinfo() function using php file over web browser it shows PHP Version as 5.5.6 and when I check through terminal window using php -v it shows, following message:
PHP 5.6.11-1ubuntu3.4 (cli) Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2015 Zend Technologies
with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2015, by Zend Technologies
So, I need to know which is my current php version and which version is running in my lamp server.