Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

xdebug not running on mamp

Tags:

php

xdebug

mamp

I am trying to run xdebug on mamp and followed many tutorials but when i see it in my phpinfo() i don't find xdebug. As xdebug is already included in the mamp as i read.This is line i added in my php.ini and i also went to that location to see if xdebug.so exist or not.but still its not working. any help? i am using mamp 2.1.2

p.s I modified the php version to mine in php.ini from php5 to php5.4.10

like image 569
localhost Avatar asked Feb 27 '13 14:02

localhost


2 Answers

I don't know if it's too late but i'm sure that someone will need the real answer.

To solve yo online have to change php.ini in the correct path...

For php 5.4.10 there are two php.ini and I changed both and it works for me. They are in:

MAMP/conf/php5.4.10/php.ini
and
MAMP/bin/php/php5.4.10/conf/php.ini

When I changed the second one, I reload MAMP and IT WORKS!! If you want to know if it's working, open MAMP on localhost, click phpinfo and find xdebug.

Also, I have to say that I changed in httpd.conf (MAMP/conf/apache) the port 8888 to 80 (you have to change Listen:8888 to Listen:80 and local_host:8888 to local_host:80. (without _) In that case, yo only have to go to http: / / localhost to see your projects

like image 194
Aarranz Avatar answered Nov 18 '22 07:11

Aarranz


Thanks @titolancreo!!

I was about to give up for today after a couple hours and just by adding the same line in both php.ini it suddenly worked!

you can also do this in your terminal to know if it works:

php -m

You should be able to see the Xdebug module two times, one in the [PHP Modules] list and another one in the [Zend Modules] list.

like image 20
JoanCasas Avatar answered Nov 18 '22 09:11

JoanCasas