问题
I am configuring debugger on phpstorm on Ubuntu. I easily could set interpreter's path like C:xampp/php properly on Windows. But linux should have different path for interpreter.
I searched on this site a lot and on google too but could not get the answer. What should be php's interpreter path so that phpstorm recognizes it and thus i can do debugging? Anything missing??
Thanks.
回答1:
I think there's been a misunderstanding. include path should point to a folder containing PHP files, not PHP interpreter!
Here's where you need to set the address:
As the other answer pointed out, you can find the path to your PHP interpreter using which php or which php5. Then you need to enter the path in the red box numbered 2.
回答2:
Not sure if it helps, but default place for php5 executable on ubuntu is
/usr/bin/php5
PS: you can find out it by typing in a terminal
which php5
PS2: I set up xdebug using this wonderful article: http://blog.elenakolevska.com/debugging-laravel-on-homestead/ (it requires Homestad -- Laravel Ubuntu box for Vagrant, but maybe it will be usefull for you too)
回答3:
For Linux Users, the Interpreter is not located into /opt/lampp/php. In fact it is located in /opt/lampp/bin/php. So provide this directory for the CLI interpreter. It can be seen in Screenshot:
来源:https://stackoverflow.com/questions/32123921/ubuntu-phpstorm-interpreter-is-not-specified-or-valid