30.07.2012 Views

Reference Guide

Reference Guide

Reference Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Zend Server <strong>Reference</strong> Manual<br />

Configuring Zend Framework<br />

Configuring Zend Server to Run a Zend Framework Application<br />

The following procedure describes how to configure Zend Server to run Zend Framework projects in a<br />

development environment, using port-based virtual hosts. The advantage of port-based virtual hosts is in<br />

the ease of running several isolated applications on the same Web server. This overall solution allows<br />

developers working on a Zend Framework project in Zend Studio to immediately test any code changes<br />

locally.<br />

The following procedure uses instructions suitable for Zend Studio for Eclipse and the Apache<br />

bundled with Zend Server. A similar procedure with some modifications can apply for other IDEs and web<br />

servers.<br />

414<br />

To configure Zend Server to run a Zend Framework application:<br />

1. Create a new Zend Framework project.<br />

If you have not already done so, create a new Zend Framework project using the New<br />

Zend Framework Wizard in Zend Studio for Eclipse.<br />

2. Define a virtual host on Zend Server that will point to the new project's public directory:<br />

a. Find the full path to your project's public directory.<br />

In Zend Studio for Eclipse, go to the project browser and right-click on the public<br />

directory from the menu choose Properties. The full path is listed in the<br />

Resource Tab's location field.<br />

b. Open your Apache configuration file (in most cases it will be httpd.conf and<br />

located in your Apache installation directory).<br />

Where is my Apache configuration file?<br />

c. Go to the end of the file and add the following section:<br />

Listen 10089<br />

< VirtualHost *:10089><br />

DocumentRoot " DOCUMENT_ROOT"<br />

<br />

Order allow,deny<br />

Allow from all<br />

AllowOverride all<br />

<br />

<br />

3. Replace "DOCUMENT_ROOT" with the full path to the public directory, enclosed in

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!