Zend Framework is an open-source object oriented application framework for PHP 5.
It uses an advanced Model-View-Controller implementation designed to help you provide a basic framework of your Zend Framework applications.
Zend Framework is often referred as the component library because it has a lot of loosely coupled components that you can use independently.
It is designed for programmers as it allows them to focus more on their project that doing repetitive codes.
Zend framework is not installed by default in most hosting providers. If you want to use Zend Framework, install it yourself. Zend Framework can typically work with all servers and hosts.
How to install Zend Framework on a Hosting Provider
It is important to be aware that most web hosts run an older version of PHP.
If your web hosts run an older version of PHP, and you cannot compile your own version of PHP you can try sending a PHP changelog to your web host and encourage them to upgrade to the current stable version of PHP.
If you are looking for a new host, look for a host that runs the latest stable version of PHP (currently supports PHP 5.2.11 or later) with the following features:
Apache 2.2 or later
MySQL 5.1 or later
web server configured to handle PHP scripts
Additional extensions for use with Zend Framework like mod_rewrite to clean urls.
Installing Zend Framework on Unix and Linux
- Download the latest full version of Zend Framework
- Extract ZendFramework-xx.tar.gz then rename it as ZendFramework
- Copy ZendFramework to your local system folder, use the following command in your terminal:
- sudo cp -r ~/Downloads/ZendFramework /usr/local/
- Then type: sudo gedit ~/.bash_aliases
- Add the following line: alias zf=’/usr/local/ZendFramework/bin/zf.sh’
- Save then exit
- Reload .bash_aliases using this command: source .bash_profile
- Test your zf tool installation: zf show version. A Zend Framework version should appear.
- Install Pear and PHPUnit
- Check your PHPUnit version to see if it has successfully installed:
- Open your php.ini configuration file
- Find the following line and uncomment it:
- ; UNIX: “/path1:/path2”
- include_path = “.:/usr/share/php”
- Install XDebug
- Locate the XDebug Path: locate xdebug
- Add the followign line to your php.ini
- Find this line: Development Value: E_ALL | E_STRICT then uncomment it.
- Restart your apache server: sudo /etc/init.d/apache2 restart
- Type in your browser localhost/phpinfo.php, then search for the Zend logo.
<?php
phpinfo();
?>
To test if Xdebug is successfully installed.
Zend Optimized Hosting
InterServer, a a popular and reliable web host with good support, has Linux Zend optimized servers and has included a free automated installation of Zend to save you time.
How To Install Zend Framework in Windows
- Simply download the installer from Zend website, and install it.
- You can use the custom installation to change the port number of your services. By default, the port number should be set to 8080.
- This assumes that you have already set up PHP/Apache server separately or have installed MySQL components.
- Test your installation to ensure that Zend Framework is installed correctly.
Zend framework has all the object-oriented goodness, you can extend the class to allow developers to implement variations of individual components without having to hack into ZF codebase and allows you create a functionality unique to your project.
These are some of the reasons Zend Framework is a popular choice for most programmers and web developers.