[Zz]netbeans+php+debug

Source: Internet
Author: User
Tags php development environment netbeans
Netbeans with PHP is easy to install, plus a xampp, basically invincible, PHP development environment has.
XAMPP Download Address: http://www.apachefriends.org/zh_cn/xampp-windows.html
After the author test, if the Download lite version, PHP does not have xdebug, and the full version directly with the Xdebug, in Php/ext/xdebug.dll
So if you're downloading lite, you'll need to download a xdebug for your PHP and OS version on the Xdebug homepage, like my php5.3,32bit windows, download 5.3 VC6
Then modify the php.ini
Add to:
zend_extension= "D:/xampplite/php/ext/php_xdebug-2.0.5-5.2.dll"
[Xdebug]
Xdebug.profiler_enable=on
Xdebug.trace_output_dir= "D:\XAMPPLite\xdebug"
Xdebug.profiler_output_dir= "D:\XAMPPLite\xdebug"
Xdebug.remote_enable=on
Xdebug.remote_handler=dbgp
Xdebug.remote_host=localhost
xdebug.remote_port=9009
The first line needs to be noted: if it is PHP5.3, it is zend_extension, and if it is PHP5.2, it is zend_extension_ts
The Remote_port can be set by itself, but it needs to be the same as configured in the NetBeans environment, with the following path:
Tools = = Option =>php=> Debugger path:

Well, on both sides of the corresponding, but there is a place to note, in the project properties, and run configuration and the debugger agent, here can not write things, we do not have agents, if the agent is understood as the debugger location, fill in the localhost:9009, but can not connect to the debugger.

OK, the following is debugging, if CTRL+F5, the single-step debugging will start, will stop in the first line (also this can be set)
Success Flag: Step out, steps out and other debugging options are on, the status bar below shows "running":

  • Related Article

    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.