Debugging with NetBeans IDE

Debugging with NetBeans IDE
image_pdfimage_print

Have you ever encountered errors in PHP code? Which debugging program did you use in such case? If you still do not have such program, it is time to learn about NetBeans IDE!

It is necessary to add these lines to php.ini:

	zend_extension_ts="/usr/local/php5/php_xdebug-2.0.4-5.2.8.dll"
	xdebug.remote_enable=on
	xdebug.remote_host=127.0.0.1
	xdebug.remote_port=9000

xdebug.remote_handler=dbgp

Note: How to find the file php.ini on your computer? Here it is explained how to do this.

After the installation it is necessary to create the new project for debugging and to specify the path to your resource:

Creation the new project for debugging in NetBeans

When you created the new project, it is possible to:

    1. Open the project in the browser:
      Открыть проект в браузере
    2. Open the project in the new window of the browser for debugging:
      Open the project for debugging

When you open the project for debugging in the browser, you’ll see a message:

Launching. Please wait…

It means that single-step debugging has started. Use NetBeans for debugging!


  Please, Login or Register to get the download link.

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *