User Guide > Tasks > Working with Libraries > Deploying Libraries

Deploying Libraries

This page describes how to deploy a PHP Libraries.

Important!

Deploying libraries can only be performed on Zend Server 6.1 and above. Deploying to Zend Developer Cloud is currently not supported.

Deploy a Project as a Library

This procedure describes how to deploy a PHP project as a PHP library.

 

 

Instructions on how to complete a procedure

To deploy a project as a library:

  1. Right-click your project in the PHP Explorer, and select Configure | Add Application Deployment Support.
    If deployment support has already been added to the project, skip to the next step.
  2. Open the project's 'deployment.xml' file.
  3. In the General Information area, change the project type to 'library'.
  4. In the Testing area, click Deploy as PHP Library.
    The Deploy PHP Library dialog is displayed.

  1. Configure the deployment options:

    • Deploy to - Select the target you wish to deploy the library to, or click Add Target to add a new target. For more information on adding targets, see Managing Targets.
    • Add to PHP Libraries - Select this check-box to add the created library to shared location and to PHP Libraries list.
  2. Click Finish.
    Your new PHP library is deployed to the selected target.

 

Note:

Libraries cannot be redeployed. If you wish to deploy a library that already exists, change its name or version, or remove from server.

Tip:

To use this library in a project, you will need to add in to the project's include path. For more information, see Using Libraries.

Deploying Existing Libraries

These procedures describe how to deploy libraries already existing on Zend Studio's PHP Libraries list.

Deploying from the Targets View

This procedure will describe how to deploy an existing PHP library from your PHP Libraries list or a library .zpk, from the Targets view.

Note:

This procedure can only be performed for Zend Server 6.1 and above targets.

 

 

Instructions on how to complete a procedure

To deploy a PHP library from the Targets view:

  1. From the menu-bar, select Window | Show View | Targets to open the Targets view.
  2. Form the targets view, right-click the target you wish to deploy the library on, and select Deploy PHP Library.
    The Deploy PHP Library on Target dialog is displayed.

  1. Select ZPK Package, and click Browse to locate and deploy a library .zpk file.
  2. Select PHP Library, and a library from the PHP Libraries list on the right, to deploy an existing PHP library. The list will also display libraries that are not in your open workspace. Click Manage to create a new library, or edit an existing one.
  1. Configure the deployment options:

    • Add to PHP Libraries (available if importing a .zpk file) - Select this check-box to add the created library to shared location and to PHP Libraries list.
  2. Click Finish.
    Your new PHP library is deployed to the selected target.

 

Note:

Libraries cannot be redeployed. If you wish to deploy a library that already exists, change its name or version, or remove from server.

Tip:

To use this library in a project, you will need to add in to the project's include path. For more information, see Using Libraries.

Deploying from PHP Preferences

This procedure will describe how to deploy an existing PHP library from your PHP Libraries list using the PHP Preferences dialogs.

Note:

This procedure can only be performed for Zend Server 6.1 and above targets.

 

 

Instructions on how to complete a procedure

To deploy a PHP library from PHP Preferences:

  1. From the menu-bar, select Window | Preferences | PHP | PHP Libraries.
    -OR-
    In the tool-bar, click the PHP Libraries icon .
    The PHP Libraries preferences dialog is displayed.

  1. Select the library you wish to deploy, and click Deploy to Target.
    The Deploy PHP Library dialog is displayed.

  1. Select the target you wish to deploy the library to, specify a library version (if required) and click Finish.
    Your new PHP library is deployed to the selected target.

 

Note:

Libraries cannot be redeployed. If you wish to deploy a library that already exists, change its name or version, or remove from server.

Tip:

To use this library in a project, you will need to add in to the project's include path. For more information, see Using Libraries.

 

 

Related Links

Related Links:

Importing Libraries

Using Libraries

 

 

©1999-2013 Zend Technologies LTD. All rights reserved.