php.ini in Wampserver 3.2
Posted by: Trader (185.69.144.---)
Date: July 31, 2020 10:06PM

I have just downloaded Wampserver 3.2 to use with Komodo IDE 12. I have used the PHP Xdebug extension to configure Wamperver for Local Debugging.

The Xdebug summary report says that " directories adjacent" to the the line Zend_extension="c:wamp64/bin/php/php7.3.12/ext/php_xdebug-2.9.6-7.3-vc15-x86_64.dll" -line 1800 in the php.ini file 'seem to be configured with a separate php.ini file for the webserver and command line.'

Will someone please tell me what these lines aren and how to go about making sure that they are all pointing to the same php.ini file.
I am not well versed in php.in configuring and I need someone who knows what he/she is doing to help because the IDE is giving me the message " Warning Failed to configure for Local Debugging."

Thanks in advance

Options: ReplyQuote
Re: php.ini in Wampserver 3.2
Posted by: Otomatic (Moderator)
Date: August 01, 2020 10:06AM

Hi,

> seem to be configured with a separate php.ini file for the webserver and command line.
PHP ini for Webserver is :
Left-Click -> PHP -> php.ini
That is the php.ini symbolic link which is in the bin folder of the Apache version used, for example :
c:\wamp64\bin\apache2.4.43\bin\php.ini
This symbolic link corresponds to the phpForApache.ini file of the web version of PHP, for example :
c:\wamp64\bin\php\php7.4.8\phpForApache.ini

For this same PHP version, the CLI ini is php.ini
c:\wamp64\bin\php\php7.4.8\php.ini

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote
Re: php.ini in Wampserver 3.2
Posted by: Trader (84.68.16.---)
Date: August 04, 2020 07:27PM

Thank you for your response. I am still unclear about where exactly I should write these paths in the php.ini file.

The Xdebug instructions mentioned "adjacent directories" without indicating the names of the variables in the php.ini file to which these paths should be assigned. Clarification on this matter would be very helpful. Thanks in advance.
For clarification, I am including a copy of the Xdebug report . Instruction No 4 is what is giving me problems.
Thanks in advance


July 31 2020 16:58 UK Time
Installation Wizard
Xdebug
Summary
• Xdebug installed: 2.8.0
• Server API: Apache 2.0 Handler
• Windows: yes - Compiler: MS VC 15 - Architecture: x64
• Zend Server: no
• PHP Version: 7.3.12
• Zend API nr: 320180731
• PHP API nr: 20180731
• Debug Build: no
• Thread Safe Build: yes
• OPcache Loaded: yes
• Configuration File Path: C:\WINDOWS
• Configuration File: C:\wamp64\bin\apache\apache2.4.41\bin\php.ini
• Extensions directory: c:\wamp64\bin\php\php7.3.12\ext
Instructions
1. Download php_xdebug-2.9.6-7.3-vc15-x86_64.dll
2. Move the downloaded file to c:\wamp64\bin\php\php7.3.12\ext
3. Update C:\wamp64\bin\apache\apache2.4.41\bin\php.ini and change the line
zend_extension = c:\wamp64\bin\php\php7.3.12\ext\php_xdebug-2.9.6-7.3-vc15-x86_64.dll
Make sure that zend_extension = c:\wamp64\bin\php\php7.3.12\ext\php_xdebug-2.9.6-7.3-vc15-x86_64.dll is below the line for OPcache.
4. Please also update php.ini files in adjacent directories, as your system seems to be configured with a separate php.ini file for the web server and command line.
5. Restart the webserver

Options: ReplyQuote
Re: php.ini in Wampserver 3.2
Posted by: Otomatic (Moderator)
Date: August 04, 2020 08:25PM

Hi,

Wampserver 3.2.0 comes with xDebug already installed for all versions of PHP.
Look at the end of the PhpForApache.ini files

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote
Re: php.ini in Wampserver 3.2
Posted by: Trader (84.68.60.---)
Date: August 05, 2020 01:17PM

To get the information shown by Xdebug wizard, I was required to upload the whole of the php info file into the wizard's start up page. So I guess that "adjacent directories" refers to entries in the php.ini file referred to by the php info() file.My problem is to identfy which lines in this file I am to update and with what information.

Options: ReplyQuote
Re: php.ini in Wampserver 3.2
Posted by: Otomatic (Moderator)
Date: August 05, 2020 01:34PM

Hi,

> 4. Please also update php.ini files in adjacent directories, as your system seems to be
> configured with a separate php.ini file for the web server and command line.

I think you should copy the lines from the [xdebug] section of the phpForApache.ini file to the end of the php.ini file because the php.ini file is for PHP CLI and does not load xDebug by default.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote
Re: php.ini in Wampserver 3.2
Posted by: Trader (84.68.60.---)
Date: August 05, 2020 05:44PM

Thanks for the reply re Apache files. Before making changes to the end of the php.ini file, I wanted to let you know the Xdebug related lines at the very end of the file (php.ini file) referred to by phpinfo() so that you may decide what lines are appropriate to add to the file at the very end.


The following are the Xdebug related lines at the end of the php.ini file:

;openssl.capath=

; Local Variables:
; tab-width: 4
; End:
; XDEBUG Extension
[xdebug]
zend_extension="c:/wamp64/bin/php/php7.3.12/ext/php_xdebug-2.9.6-7.3-vc15-x86_64.dll"
xdebug.remote_enable = off
xdebug.profiler_enable = off
xdebug.profiler_enable_trigger = Off
xdebug.profiler_output_name = cachegrind.out.%t.%p
xdebug.profiler_output_dir ="c:/wamp64/tmp"
xdebug.show_local_vars=0

Options: ReplyQuote
Re: php.ini in Wampserver 3.2
Posted by: Otomatic (Moderator)
Date: August 05, 2020 06:29PM

Hi,

phpinfo() refers to what it "sees" as a configuration, so what you see in phpinfo() is an exact reflection of what is in the [xdebug] section, so you copy the whole thing.

Then, as needed, you may need to modify or add xDebug directives, but I can't make that decision for you.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote
Re: php.ini in Wampserver 3.2
Posted by: Trader (84.68.60.---)
Date: August 05, 2020 08:52PM

Problem sorted.
My Local PHP Debugging is now working as expected.
Thank you very much for your help.

Options: ReplyQuote


Sorry, only registered users may post in this forum.