phpstorm xdebug with a symfony2 project

前端 未结 5 1191
無奈伤痛
無奈伤痛 2021-02-04 11:52

I am trying to debug a symfony2 application with xdebug and phpstorm.

My local development environment is Ubuntu 14.04 with apache2 and Xdebug version is 2.2.7

I

5条回答
  •  误落风尘
    2021-02-04 12:31

    I don't know which browser you are using, but, using Chrome, I use the Xdebug helper extension.

    Once the extension is installed, right click on it > options and select PHPStorm as IDE.

    Then, start listening for connection on PHPStorm using the button near the debug one.

    EDIT:

    Here is my configuration of XDebug:

    zend_extension=/usr/lib/php5/20121212/xdebug.so
    xdebug.max_nesting_level = 1000
    xdebug.collect_params = 1
    xdebug.collect_return = 1
    xdebug.remote_enable = 1
    

    Are you sure XDebug is properly installed on your machine ?

    When in PHPStorm > Run > Edit Configurations..., add a PHP Web Application debugging profile and fill it this way:

    • Name: Acme Project
    • Server: apache2 (you might need to add yours - name, port, adresse, debugger)
    • Start URL : /app_dev.php
    • Browser: Default

    Press OK and you're done !

提交回复
热议问题