E
E
Evgeny Ivanov2018-07-29 14:05:21
PHP
Evgeny Ivanov, 2018-07-29 14:05:21

How to setup PhpStorm 2016.1.2+Openserver?

Installed PhpStorm and Openserver. Everything "individually" works.
As I understand it, the only purpose of PhpStorm + Openserver is to "replace" the outdated local PhpStorm server with a modern Openserver with all the settings, possible additions, debuggers, etc.
Configuring PhpStorm Settings->Languages ​​and frameworks->PHP->Interpreters->PHP Executable
D:\Cloud folder\Personal folders\E_Ivanov\Synchronized files and folders\Open_Server\modules\php\PHP-7.1-x64\php.exe
PhpStorm writes - configuration php.ini file does not exist. But php.ini is there, of course.
I watch How to fix. It says create it there. But he is there! Even PhpStorm's file selection window has it.
Or create it in c\windows. Copied it there. Does not see. The file is there, but still - configuration php.ini file does not exist.
Good.
I take the entire PHP-7.1-x64 folder and copy it to D:\Program Files\PhpStorm 2016.1.2\PHP-7.1-x64_copy_from_openserver I specify
the path to \php.exe Everything is found. Apply, Ok.
Starting Openserver. I open PhpStorm. I am creating a project. On the right I see browser icons.
I press - the browser opens and 502 Bad Gateway PhpStorm 2016.1.2
How to configure PhpStorm 2016.1.2+Openserver?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
E
Eugene Volf, 2018-07-29
@Wolfnsex

As I understand it, the only purpose of PhpStorm + Openserver is to "replace" the outdated local PhpStorm server with a modern Openserver with all the settings, possible additions, debuggers, etc.

PhpStorm's goal is to provide an IDE. The purpose of OpenServer is to provide a complete (to some extent) development and execution environment for PHP scripts/applications/sites/etc. In addition to the PHP interpreter, OpenServer has a lot of other modules (programs), depending on the "configuration": from various databases, for all sorts of "offices", etc. This is due to the fact that most projects are not limited solely to the PHP interpreter, many also require various databases, sometimes storage (for example, Redis or Memcached) and other tools.
PhpStorm writes - configuration php.ini file does not exist. But php.ini is there, of course.
Perhaps this is due to the fact that the paths contain something other than Latin letters (sometimes spaces in the paths can also interfere, although this happens much less often).
Usually, the process looks like this:
0. Specifying the path to the PHP interpreter is not always necessary or necessary, sometimes you can completely do without it
1. In the folder where OpenServer is installed, among other things, there is a domains folder in which you create a folder with the future project (site) and name it, for example, site1.local
2. (Re)start OpenServer, it is highly desirable to do this with administrator rights, it will make changes to the hosts file of the system so that the site becomes available according to the acc. address (in this example, at:site1.local )
2.1. You can also open the project through the OpenServer menu: My sites -> "Desired site"
What would the project be opened in PhpStorm according to. ("correct") address, instead of the built-in web server - I think you need to change some project settings in PhpStorm (it's hard to say which ones, because I've never used this way of working with the project).
PS In order to debug a project in different browsers, they usually use different BrowserSync's, LiveReloads, etc.
PPS If you need a simple web server with PHP support, exclusively for development/debugging - such a server is in PHP itself .

V
Vladislav Lyskov, 2018-07-29
@Vlatqa

and if you take puff from the site's office?

M
Michael, 2018-08-02
@springimport

If I understand you correctly. Right now I installed OP and IDE on the virtual machine.
Adding php:
File:
In general - the tools work better under linux (ubuntu). As a last resort, there is a docker that will get rid of Windows problems. Well, install nginx, it is 10 times faster than apache.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question