Running Applications on Local Zend Servers

This tutorial will explain how to locally create and launch a new project on your machine.
You will not be using deployment as part of the workflow.

If you wish to work with deployment, see Deploying Applications to Zend Server and Building Applications on the Zend Developer Cloud.

In this Tutorial you will Learn

Prerequisites

Step 1: Creating a New Local Zend Framework Project

You will now create a new Zend Framework local project to work with in this tutorial.

 

 

Instructions on how to complete a procedure

To create a new local Zend Framework project:

  1. Open Zend Studio.

  2. From the Menu bar, select New | Local PHP Project.

Settings_dialog.png

  1. Enter the following information:

  • Project Name- Name your project “LocalProject”

  • Location- The project location for this tutorial is ‘C:\Program Files(x86)\Zend\Apache2\htdocs’

  • Content -  Select Zend Framework

  • Version – Leave as the default

  1.  Click Next to move to the Launch Settings dialog.

Launch_settings_dialog.png

  1. Select Launch URL, and click Finish.
    Your new project is created and appears in the PHP Explorer view.

LocalProject_created.png

 

 

 

Step 2: Debugging Your Application

The Zend Studio debugging function allows you to test your files and applications and detect errors in your code. The debugger allows you to control the execution of your program using a variety of options including setting breakpoints, stepping through your code, and inspecting your variables and parameters.

 

 

Instructions on how to complete a procedure

To debug your application:

  1. In the PHP Explorer, right-click the project and select Debug As | PHP Web Application.
    A dialog is displayed confirming the launch URL.

  2. Click OK.

  1. When prompted to open the Debug perspective, click Yes.
    Your application appears in the Debug perspective and stops at the first breakpoint.

DebugPerspectiveForDaniel.png

  1. To continue the debug click Debug_Icon.png.

 

Step 3: Modifying your Code

To be able to view any changes made to the code in your application, this tutorial will first explain how to modify the code.

 

 

Instructions on how to complete a procedure

To modify the code of your application:

  1. Return to PHP Perspective by clicking on the PHP Perspective icon PHP_Perspective_Icon.png.

  2. In the PHP Explorer view, expand your project and go to Application| View | Scripts | Index | index.phtml

  3. Make a small textual change and save the project.

 

Step 4: Running Your Application

You will now run the application to see it with the modified code.

 

 

Instructions on how to complete a procedure

To run the application:

  1. In the PHP Explorer view, expand your project and go to Public | index.php .

  2. Right-click the index.php file and select Run As | PHP Web Application.
    Your application appears in the internal Web browser with the changes.

RunningApplicationForDaniel.png

 

 

 

 

Related Links

Related Links:

Deploying Applications to Zend Server

Building Applications on the Zend Developer Cloud