Remote Debugging php

Source: Internet
Author: User
To remotely Debug php, you must first ensure that zenddebugger is correctly installed on the server. You can use phpinfo to view the information. The dummy. php file is located in the root directory of the server. In addition, you also need to change the php. ini of the server? Zend_debugger.allow_hosts127.0.0.1zend_debugger.expose_remotelyalways change to ze remote debugging php

First, make sure that zend debugger is correctly installed on the server. You can use phpinfo to view the information. The dummy. php file is located in the root directory of the server. In addition, you also need to change the php. ini of the server

?

Zend_debugger.allow_hosts = 127.0.0.1
Zend_debugger.expose_remotely = always

Change

Zend_debugger.allow_hosts = 127.0.0.1, 192.168.0.102
Zend_debugger.expose_remotely = always

?

Here, the newly added IP address is the IP address of the client. make sure that the two machines are pinged and disable the firewall or something. The zend debugger port is used for transmission.

?

Then we use aptana as the debugging tool. My aptana has been installed with pdt and zend debugger plugin.

First, open preference and create a new server in the php server. The address is the server address, for example, http: // 192.168.0.101.

Select another php page, right-click a debug as option, select debug configuration, select the new one in the php server column, and then click configure of the php server. There is a path mapping in it. In the first column, write the folder of the file to be debugged on the server, for example, d:/debugtest/. Note that this path is the server path and cannot be entered as your own. Select the corresponding folder of your workspace. Make sure that the two directories correspond, and the code should be the same.

Then let's debug it. Adjust the url. if the url fails, change the value of debughost after the url address to 192.168.0.102. Refresh the page and you can debug it.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.