How can I enable Zend on the Grid?


Browse by products and services

  • Applies to: Grid
    • Difficulty: Medium
    • Time Needed: 20
    • Tools Required: SSH access or FTP and AccountCenter access

Overview

Zend Guard Loader is a free runtime application that enables PHP to run the scripts encoded by Zend Guard. Zend is a trademark of Zend Technologies Ltd.

NOTE:

If your scripts are encoded with a version of Zend Guard that is earlier than 5.5, they will not work with Zend Guard Loader. Please consult the developer of your application to have them re-encode your files to work with Zend Guard Loader.

Requirements

Before you start, you should have handy or be familiar with:

READ ME FIRST

This article is provided as a courtesy. Installing, configuring, and troubleshooting third-party applications is outside the scope of support provided by (mt) Media Temple. Please take a moment to review the Statement of Support.

Instructions

(mt) Media Temple does not provide the PHP modules for Zend Guard Loader. You are welcome to compile these yourself. This tutorial has been adapted from: Working with Zend Guard.

Begin by confirming that your domain is using PHP 5.5 or 5.6. Older versions (php 5.3) are provided via link at the bottom of the downloads page. These older versions are no longer supported and it is recommended that you upgrade if possible. For more information, please see: How can I specify the PHP version on the Grid? 

Note: PHP versions 5.6 and 7 are currently only available for Grid Personal, Pro, and Agency plans. You can find out more about these great Grid hosting packages here.
  1. Navigate here and select Linux from the operating system drop-down menu. Download Zend Guard Loader (Runtime for PHP 5.5 or 5.6). Regardless of your PHP version, you must download the 64 bit binaries. This includes downloads for older versions as well.

  2. Upload the tarball to the /data/tmp directory on your Grid via FTP or SSH.
  3. Connect to your Grid via SSH.
  4. Navigate to /data/tmp and extract the uploaded tar.gz file. Run each command separately:
    cd data/tmp
    tar xzvf filename.tar.gz
  5. Next, add the following line to your php.ini file for loading the ZendGuardLoader:
    zend_extension=/home/00000/data/tmp/<filename of version you downloaded (see Figure 1 above)>/php-5.3.x/ZendGuardLoader.so

    TIP:

    Be sure to replace 00000 with your site number.

    Add an aditional line to your php.ini for enabling ZendGuardLoader:

    ; Enables loading encoded scripts. The default value is On
    zend_loader.enable=1
  6. You can verify that Zend Guard Loader has been successfully installed by creating a phpinfo() page. For detailed instructions, please see: How can I create a phpinfo.php page? See Figure 2 as an example.


    Figure 2. This phpinfo() page shows Zend Guard Loader.

Resources