Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Intellij Project Structure: Configure PHP SDK

starting with Intellij 13.1 which was released today, it is possible to configure additional SDKs in the Project Structure dialoge. While the old 13.0 version only contained the following three items when clicking on the new button:

  • JDK
  • IntelliJ Platform Plugin SDK
  • Mobile SDK

The new 13.1 update has added several more options as can be seen on the screenshot: enter image description here

When I click on PHP Interpreter then a directory chooser opens and ask me for the "Select Home Directory for PHP Interpreter". Which folder is the correct one under Ubuntu?

I have tried /usr/bin and I get a message that says: Probably SDK installed in '/usr/bin' is corrupt, and when I choose another directory then the message says: The selected directory is not a valid home for PHP Interpretor.enter image description here

However, when I go to Settings->PHP I have already correcly configured PHP 5.4 and when I open the details by clicking on '...' then I see the following:

enter image description here

Has anyone tried this? Am I doing something wrong, or is this a bug in IntelliJ maybe?

like image 362
lanoxx Avatar asked Mar 19 '14 12:03

lanoxx


1 Answers

Open a new local shell/terminal window and type which php this will tell you where the php binary is installed

in some ubuntu releases the repo's install php as php5, if that is the case you might need an ln -s to php

Although in my PhpStorm (PS-138.2071) it looks like this : enter image description here

like image 128
DarkMukke Avatar answered Nov 27 '22 07:11

DarkMukke