Book Image

PHPEclipse: A User Guide

Book Image

PHPEclipse: A User Guide

Overview of this book

The fusion of Eclipse, the leading open source development environment, and PHP is an exciting prospect for web developers. This book makes sure that you are up and running as quickly as possible, ready to take full advantage of PHPEclipse's tuned PHP development tools, without requiring any prior knowledge of Eclipse. You will begin with installing and configuring PHPEclipse, before moving onto a tour of the Eclipse environment, familiarizing you with its main components. As a plug-in to Eclipse, PHPEclipse is able to harness the platform to provide a rich and powerful development experience. For helping you improve the efficiency of your PHP coding, the book details the powerful editing features of PHPEclipse, and shows you how to use it to better organize your application code. You will see how PHPEclipse helps you throughout the development lifecycle, and learn how to use PHPEclipse's debugger to troubleshoot and step through your PHP code as it executes. The book rounds off with coverage of accessing databases and managing source code from within the. For the final step for your application, you will learn how to deploy your site to a production server."
Table of Contents (12 chapters)
11
Index

Navigating Through a Debugging Session

If you haven’t stopped the previous debugging session, do so now. In the Debug view, click on the Terminate button in the toolbar. The Debug target line will now have<terminated> at the beginning and the icon will lose its motion arrows, indicating that the process has stopped. Click on this motionless Debug target line to highlight it and click on Remove All Terminated Launches to remove it from the view.

Let us try a slightly more complicated debugging exercise. Now that we have a familiarity with the Debug perspective and what we’re looking at, let’s try to navigate through a session. Debugging in PHPEclipse follows industry-common practices and works very similarly to debugging in other IDEs. The terms you encounter here can be carried over to other languages and other tools.

First, replace the code in debug.php with this code. This code sets some variables, and calls a local function. The local function returns a value...