* Adding pipeline * del jenkinsfile * Make exec agent not to use setsid for other than Linux envs * revert pom.xml * goformat * get projects folder from workkspace configuration * Merge remote-tracking branch 'upstream/master' * clean code * clean code * Fix calculation Projects Root so it wont cause NPE if there are no 'project' volume defined * Revert "Fix calculation Projects Root so it wont cause NPE if there are no 'project' volume defined" This reverts commit 127a79e54c3e7f97a74f0103506025eb5e181777. * Fix calculation Projects Root so it wont cause NPE if there are no 'project' volume defined * replace provided attribute values with stored (src, out) in PlainJavaProjectType * fix PlainJavaProjectType for getting rid and deprecate using SettableValueProvider * remove comented code * hide brouse source folder button, set source folder field as disabled * hide the browse source button, set source folder field to read only mode, remove highlighter from the source folder field * adapt test for current changes on UI, set save button to enable state * apply formatting * fs cache PT * fix order of steps in the test * Refactor RegisteredProject to make it possible to cache it (as DTO) to local file * cache Projects and PTs to files * Make it possible to have several impls for ProjectRegistry preparing it to be distributed across multi machines env * merge upstream * merge upstream * merge upstream * Update MavenServerService.java * clean code * small fix * small fix * small fix |
||
|---|---|---|
| .. | ||
| che-plugin-zend-debugger-ide | ||
| che-plugin-zend-debugger-server | ||
| README.md | ||
| pom.xml | ||
README.md
Zend Debugger for PHP
Support for debugging applications that runs on PHP with Zend Debugger on board.
Requirements
Zend Debugger is a PHP extension that needs to be installed and enabled in the PHP distribution available in the Che stack. If you decide to use ZEND stack to create your workspace you can skip "Zend Debugger Installation" part as Zend Debugger is already installed in ZEND stack's PHP. If you decide to use default PHP stack to create a workspace, you will have to follow the instructions from the next chapter to install Zend Debugger extension.
Zend Debugger Installation
The following steps have to be carried out to install Zend Debugger in Che's default PHP stack.
- Create new workspace with the use of PHP stack from the Ready-to-go Stacks list
- Download Zend Studio Web Debugger - PHP 5.5 and PHP 5.6 (64 bit) package from Zend Downloads
- Add ZendDebugger.so file from downloaded package to /usr/lib/php5/20131226
- To enable debugging applications in CLI mode, add the following entry in /etc/php5/cli/php.ini file:
zend_extension=ZendDebugger.so; - To enable debugging applications in WEB mode, add the following entries in /etc/php5/apache2/php.ini file:
zend_extension=ZendDebugger.so;
opcache.enable=0;
Getting Started
To be able to debug PHP code, you have to start Zend Debugger client in Che and run your PHP Web/CLI application with the use of some additional parameters that are required to trigger debug session in PHP. In case of debugging PHP Web applications you can use the tools like Z-Ray (available in ZEND stack) or Zend Debugger Toolbar for Firefox to trigger debug session without need to add debug parameters to URL that runs your PHP application.
Starting debug client in Che:
- Go to Run -> Edit Debug Configurations...
- Create new PHP - ZEND DEBUGGER configuration with default settings
- Press Debug button to start Zend Debugger client
Starting debug session in CLI mode:
- Use
cd <your-php-app-dir>command in terminal - Run PHP script in terminal with the use of the following command:
QUERY_STRING="start_debug=1&debug_host=localhost&debug_port=10137" php <your-php-app>.php
Starting debug session in Web mode:
- Start Che's local PHP server with your project on board
- Open the following URL in a browser:
<your-php-app-URL>?start_debug=1&debug_host=localhost&debug_port=10137
Starting debug session in Web mode with Z-Ray (ZEND stack only):
- Open an URL in a browser that runs your PHP application in the Che's local Zend Server
- Use one of the commands for starting debug session available in Z-Ray toolbar (bug icon) i.e. Debug Current Page
Starting debug session in Web mode with Zend Debugger Toolbar for Firefox:
- Install Zend Studio Browser Toolbars - Firefox from Zend Downloads
- Open an URL in a Firefox browser, that runs your PHP application in the Che's local server
- Use one of the commands for starting debug session available in Zend Debugger toolbar (bug icon) i.e. Debug Current Page
Happy PHPing!