The PHP Debugger
The Enterprise Architect PHP Debugger enables you to debug PHP.exe scripts. This section discusses basic setup and the various debugging scenarios that are commonly encountered; the scenarios concern themselves with the mapping of file paths, which is critical to the success of a remote debugging session.
• | Local Windows Machine (Apache Server) |
• | Local Windows Machine (PHP.exe) |
• | Remote Linux Machine (Apache Server) |
• | Remote Linux Machine (PHP.exe) |
Topics
|
|
|
Script Setup
|
An Analyzer Script is a basic requirement for debugging in Enterprise Architect; you create a script using the toolbar of the Execution Analyzer.
Select PHP.XDebug as the debugging platform; when you select this platform the property page displays the following connection settings:
|
|
|
port
|
9000
|
The port that Enterprise Architect listens on for the specified adaptor.
|
host
|
localhost
|
The adaptor that Enterprise Architect listens on for incoming connections from PHP.
|
localpath
|
%LOCAL%
|
Specifies the local file path to be mapped to a remote file path.
This is a remote debugging setting; for local debugging, clear the value.
The value is a placeholder; you should edit it to fit your particular scenario.
|
remotepath
|
%REMOTE%
|
Specifies the remote file path that a local file path is to be mapped to.
This is a remote debugging setting; for local debugging, clear the value.
The value is a placeholder; you should edit it to fit your particular scenario.
|
|
|
Local Machine Apache Server
|
In this situation, consider the following configuration:
• | Network computer name: MyPC |
• | Network share MyShare mapped to c:\myshare |
• | Source files in Enterprise Architect have been imported from c:\myshare\apache\myapp\scripts |
• | Apache document root is set to //MyPC/MyShare/apache |
In this scenario an Analyzer Script for the connection parameters might be configured as follows:
• | localpath: c:\myshare\apache\ |
• | remotepath: MyPC/MyShare/apache/ |
|
|
Local Machine PHP.EXE
|
In this scenario an Analyzer Script for the connection parameters might be configured as follows, as file paths always map to same physical path:
|
|
Remote Linux Machine Apache Server
|
In this situation consider the following configuration:
• | Source files in Enterprise Architect have been imported from c:\myshare\apache\myapp\scripts |
• | Apache document root is set to home/apache/htdocs |
• | Source files in Apache are located at home/apache/htdocs/myapp/scripts |
In this scenario an Analyzer Script for the connection parameters might be configured as follows:
• | localpath: c:\myshare\apache\ |
• | remotepath: home/apache/htdocs/
|
|
|
Remote Linux Machine PHP.exe
|
In this situation consider the following configuration:
• | Source files in Enterprise Architect have been imported from c:\myshare\apache\myapp\scripts |
• | Source files in Apache located at home/myapp/scripts |
In this scenario an Analyzer Script for the connection parameters might be configured as follows:
• | localpath: c:\myshare\apache\ |
|
|
Learn more
Learning Center topics
• | (Alt+F1) | Build and Debug | Debug | PHP |
• | (Alt+F1) | Build and Debug | Debug | PHP Samples |
The material ("material" includes all pages, documents and on-line graphics) on this web site is protected by copyright law. (C) 1998-2013 Sparx Systems Pty Ltd.