Installing Zend 1.11 - php

I currently have PHP 5.4 setup, can we install Zend 1.11 with it or do we need to go for Zend 2 (have not come across decent tutorials explaining the setup for Zend 2 on WAMP)
I tried installing 1.11, but it gives out a errow while using the zf CLI
***************************** ZF ERROR ********************************
In order to run the zf command, you need to ensure that Zend Framework
is inside your include_path. There are a variety of ways that you can
ensure that this zf command line tool knows where the Zend Framework
library is on your system, but not all of them can be described here.

You can absolutely run Zend Framework 1.11 with PHP 5.4.
The error you are getting is because you are trying to use "zf" in the command line, but PHP can't find where the Zend Framework is loaded. In order to fix this, find the include_path directive in your php.ini file, and update the path to include where you have installed the Zend Framework.
Don't forget to restart your web server after you have done this!

Related

PHP 5.4.31 + Zend Guard configuration issue

I am configuring a Ubuntu 14.04 web server at Amazon Web Services. I have the latest PHP5.5 installed as base, but I am using PHP Farm so that I can use PHP5.4.31 for a specific project that requires Zend Guard, which is only compatible with PHP up to 5.4.x. I added these lines to my custom php.ini
zend_extension=/usr/local/php/ioncube_loader_lin_5.4.so
zend_extension=/usr/local/php/ZendGuardLoader.so
So, everything works fine, but when I compile the PHP custom build I get this in the end:
Cannot load the ionCube PHP Loader - it was built with configuration API220100525,NTS, whereas running engine is API220100525,NTS,debug
Cannot load Zend Guard Loader - it was built with configuration API220100525,NTS, whereas running engine is API220100525,NTS,debug
Now from what can be seen, the builds are the same, the only differnce is:
API220100525,NTS vs. API220100525,NTS,debug
What I understand from this is that the PHP Zend Engine is running in Debug mode, but I can't seem to find how to disable debug mode so that the extensions can be activated.
Any ideas?
I just stumbled upon the same error.
Thanks to Marc B's hint I had a look into PHPFarm's compile.sh
There's a standard-option defined:
--enable-debug
just remove this line, delete your compiled php stuff in
/path/to/phpfarm/src/php-5.x
and recompile with
./compile.sh 5.x
Afterwards you should have a non-debug version which will work with ZendGuardLoader

Is Zend OPCache the same thing as Zend Optimizer+

I'm in a process of upgrading the PHP across all of our servers to 5.5.x
I read that the PHP team will be integrating Zend Optimizer+ within the PHP core for the 5.5 release. So I installed that but in phpinfo() there's nothing about zend optimizer+, there are only few Zend OPCache directives. So my question is, am I looking at the same thing, or should
I compile/install another extension and if so where can I find the latest version.
Thank you in advance.
Yes, it is. Here is repo for a proof: https://github.com/zendtech/ZendOptimizerPlus
Zend have some troubles with naming: Zend Optmizer != Zend Optmizer+
Now, they've opensourced it, and it is called OPCache and bundles with 5.5.

include_path error when invoking Zend Framework 2 commandline tool

When attempting to run 'create project' in Zend from command line using zf I get the following error:
In order to run the zf command, you need to ensure that Zend Framework
is inside your include_path
I'm using XAMPP and my php ini located at: C:\xampp\php\php.ini reads:
include_path = ".;C:\xampp\php\PEAR;C:\ZendFramework-2.1.1\library"
I'm running Windows 7 and my environment variables read:
C:\xampp\php;C:\ZendFramework-2.1.1\library;C:\ZendFramework-2.1.1\bin
So even though I'm referencing the framework in the php.ini it is still not recognized. Please help
Looks like a ZF1 vs. ZF2 issue.
The ZF2 command line tool ZFTool is a distinctly different creature from the ZF1 version.
Looks like you are trying to use a ZF1 tool invocation on a ZF2 installation.

Upgrading Zend Framework Advise

I am using 'MJS_Controller_PathRouter' in any ancient Zend Framework version 0.6 and PHP 5.1.6. When I run this in a newer php version e.g. 5.2.x or 5.3.x, it is throwing this error:
Declaration of
MJS_Controller_Router_PathRoute::__construct()
must be compatible with that of
Zend_Controller_Router_Route_Interface::__construct() in
/opt/ezxwebadmin-versions/ezxwebadmin_2.11.5/Library/MJS/Controller/Router/PathRoute.php
on line 34
I would like to remove this enhanced rewrite router and upgrade our application to use a newer Zend Framework version. Our web application doesn't use any of the classes provided by Zend and we are only utilizing the MVC architecture and rewrite functionality from Zend framework.
Now could any one advise which Zend Framework version would be best for us to upgrade to?
The error you are getting is actually a PHP strict coding standards error and should be fairly easy to fix. Just open up Zend_Controller_Router_Route_Interface and MJS_Controller_Router_PathRoute and compare the parameters for the __construct method. They need to be the same, so change your class to match the parameters in the interface.
Zend Framework requires PHP 5.2.4. ZF2 will require PHP 5.3+. PHP 5.1.6 is almost 5 years old so you really should be upgrading (or planning to). If you are using something like CentOS with really ancient PHP packages, you might want to consider switching to Zend Server community edition (which is free). This can be installed with Yum and will give you more recent versions of PHP.
You should take a close look at the Zend Framework Migration Notes starting at 0.8
Then look through the Zend Framework Download Archives and upgrade your framework version by version (follow the versions listed in the migration notes) to either get to a version that works with the PHP you have or (ideally) the latest version: 1.11.x

xampp zend framework and zendserver ce one don't get along well in command line

i've been using xampp 1.7.3 for a while now and today i've decided to have a look into zend framework and got a zendserver ce 5.0.2.
i'm on windows 7 and until i used the command line tool, i haven't noticed that there was a version of zend framework (zf) shipped with xampp.
zendserver got a more recent version than the xampp one. xampp was already added to the path before zend server.so command prompt is only seeing xampp one, plus it's throwing errors when creating projects.
i'ld like to use the zendserver one as default and i've tried to put the zend server bin before php in the environment variables and restarted the machine but no success.any ideas ? thanks for reading
If you cannot find how to take out the xammp zf path you could always rename/move/delete de version from xammp. Since the zend server one is on your path it should not be a problem at all.
Alternatively you could try replacing the version in xampp with the more recent one. As far as I know xampp does not use zf itself so I doubt it would break something.
If you are just trying out zend any of these solutions is pretty easy to undo. Also maybe look into virtualisation for these kind of needs. Easier to just create virtual machines then make many webservers work on the same one.

Categories