문제

I have a Linux development and testing server, that I use to create web app for my clients, before put the web app on the production server. The config of apache allow me to have "homedir" configuration, so every project has its "/home/nameproject/public_html/" directory, visible to the url http://nameserver.org/~nameproject
I work using CodeIgniter framework, and in the url there isn't index.php by using of .htaccess file, and $config['url_suffix'] = ''; in the application/config.php
Remote Server
SO: Debian
Apache: 2.2.16
PHP: 5.3.3 with Suhosin-Patch v0.9.32.1
XDebug Version: 2.1.0
Local
IDE: PhpStorm 7.1
IDE Key: PHPSTORM
Server Configuration: enter image description here
Server Configuration Mapping enter image description here

I Followed the guide Zero-configuration Web Application Debugging with Xdebug and PhpStorm, and when I start the debug session, whatever page I load, the debugger on my PhpStorm start and try to open the file index.php
Obviously, as I mentioned before, I haven't in the url any index.php...
Scenario: Click on the Listen debugger connections button, setting the breackpoint in the file: "application/controllers/auth.php" on the "forgot_password" function, and run the debugger on server,
The PhpStorm intercept the request and show me ever this screen incoming connection IMHO the Request uri = /~nameproject/auth/forgot_password cannot find the relation with "File Path On Server" that must be /home/nameproject/public_html/application/controllers/auth.php" instead of = /home/nameproject/public_html/index.php
Some idea on how to call the controller php file instead the index.php ???

도움이 되었습니까?

해결책

Accordingly to your comment .. the problem seems to be in incorrect value of "Host" field in Settings | PHP | Servers (1st screenshot) -- it should be just domain/host name and not actual URL (compare with "Server name" filed on 3rd screenshot) -- just remove /~*** part. The path mappings seems to be set up correctly.

Alternatively -- just delete any entries in Settings | PHP | Servers and use Zero-Config approach -- IDE will help setting it up on first successful debug connection.

As for 3rd screenshot -- IDE behaves correctly. Because there is no correct path mapping (with correct server/host name) PhpStorm breaks at first line of currently running script, which is index.php (entry point into your MVC application). Once correct path mapping will be established, IDE will be stopping on breakpoints only (unless it matches some criteria in "Settings | PHP | Debug | Xdebug" section).

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top