Remotely Profiling a PHP Script
This procedure describes how to profile a PHP Script from your workspace
using the Zend Debugger installed on your remote server.
Note:
Your server must be running the Zend
Debugger or Xdebug in order for remote debugging and
profiling capabilities to function.
The Zend Debugger comes bundled with Zend Studio and
Zend Server. For instructions on installing and configuring Xdebug, see Installing Xdebug and Configuring Xdebug.
|
|
|
To remotely profile a PHP script:
-
Click the arrow
next to the Profile button
on the toolbar and select Open
Profile Dialog -or- from the main menu go to Run | Open Profile Dialog
-or- right-click in PHP Explorer view and select Open
Profile Dialog.
-
A Profile dialog
will appear.
-
Double-click the
PHP Script option to create a new Profile configuration.
-
Enter a name for
the new configuration.
-
Select the PHP
Web Server option and select your server from the drop-down
list. If you have not yet configured your server, click the underlined
'PHP Servers' shortcut. The Servers preferences page will
open. Configure your server by following the instructions on adding
a new server under the PHP Servers
Preferences page. For more information on configuring the communication between
Zend Studio
and your remote server, see Setting
Up Remote Debugging.
-
Under PHP File,
click Browse and select the required file.
-
Click Apply
and then Profile.
-
A confirmation
dialog will be displayed asking whether you want to open the
Profiling Perspective. Click Yes. (If you
would like the Profiling Perspective to open by default in
the future, mark the 'Remember my decision' checkbox.)
|
The
Profiling Perspective will open, displaying the Profiling Monitor
window with various Profiling views.
See the PHP
Profile Perspective for more on the information that will
be displayed once a profile session has been run.
|
Note:
If the file contains 'include' or 'require' calls to
files which are not contained within the project, you must add
them to the project's Include Path in order to simulate your production
environment.