Which version of php is compatible with Zend Framework? - php

I used zf 1.11.11 with php 5.3.3 on a CentOS 6.x . Now i installed a new clean CentOS 7 but i can't matching php version with my old code. I can not find a repository which contains php 5.3.3 and proper Apache Server that works with my code. Also i don't know zf 1.11.11 can work with which version of php.
How can i find the proper Repository which works with yum and install appropriate php and apache for my zf application?

According to the composer.json of the framework PHP 5.6 or 7.0 is required.
To install it on CentOS 6.0 you can add the following repositoy information (according to https://webtatic.com/packages/php70/):
rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm
After that is added, run yum install php70w php70w-opcache as stated in the link above
Edit
As stated in the comments, I've misread the version number for the zend framework installation. The suggested PHP-version as pointed out by #Progrock the required PHP-version for Zend Framework 1.12 as defined in the composer.json is >=5.2.11
You can for example follow this guide to install php 5.2.17 on CentOS from museum.php.net, but I'd recommend installing one of the currently supported versions of PHP

Related

Centos php 7.1 install svn with pecl

a try install svn for php 7.1 with pecl:
pecl install svn
and i habe error:
pecl/svn requires PHP (version >= 4.0.0, version <= 6.0.0), installed version is 7.1.7
No valid packages found
install failed
What is wrong?
Thanks.
According to the error , you need a version less than or equal to php6.0 for the svn package that you are trying to install.
You can try installing a different php version thats suitable for the package or find a working package modified for php 7.1
Look at the official documentation here :
https://pecl.php.net/package/svn
The dependency is clearly stated to be php 6.0 or older
The current stable released version of PECL svn doesn't work with PHP 7. There is an open bug report current with a patch submitted to it here https://bugs.php.net/bug.php?id=75206
The patch worked for me with PHP 7.1 but it's not been officially vetted and released by the maintainers of PECL svn as of yet.

How to install php5.5 on Centos/RHEL 6.5 just via rpm?

I can't use the yum at all!
is there any php5.5 rpm file can be download to fit the the centos 6.5?
I can't use yum, so the php extension such as php55w-xml php55w-mcrypt php55w-gd php55w-devel php55w-mysql php55w-mbstring also should be downloaded in the form of rpm file.
Where can I find these rpm files?
Should I use rpmbuild to build these?
For CentOS 6, PHP 5.3.3 is the latest version of PHP available through the official CentOS package repository. Keep in mind, even though PHP 5.3.3 was released July 22, 2010, the official CentOS 6 PHP package was updated November 24, 2013. Why? Critical bug fixes are backported. See this question for more information: "Why are outdated packages installed by yum on CentOS? (specifically PHP 5.1) How to fix?"
If you'd like to use a more recent version of PHP, Les RPM de Remi offers CentOS PHP packages via a repository that you can add to the yum package manager. To add it as a yum repository, follow the site's instructions.
Note: Questions of this variety are probably better suited for Server Fault.

ZF2 install via Composer getting wrong PHP version

I have to install ZF2 on Windows:
I've clone ZendSkeletonApplication (ZSA) repository from Git
Open cmd and get in ZSA folder
run php composer.phar self-update (everything is ok)
run php composer.phar install
And now I get this:
zendframework/zendframework 2.3.1 requires php >=5.3.23 -> no matching package found.
Okay, I've checked php version php -v:
PHP 5.3.6 (cli) (built: Mar 17 2011 10:37:07)
Any ideas?
ZF 2.3.0 and above requires PHP 5.3.23 or above. You have 5.3.6 (6 is less than 23!). You either need to upgrade PHP to a more recent version, or downgrade to ZF 2.2.x.
5.3.6 is less than 5.3.23. >= means "greather than or equal to".
Zend Framework 2 requires at least 5.3.23, while you have 5.3.6. That means your PHP version is not supported, you can't use the Zend Framework on that server.
What you can do:
Update PHP version to something newer (5.3 is getting pretty old)
If you are sure you already have a newer PHP version installed, check that the cmd is using the new PHP binary and not the old one.
I suggest you update your local Windows version of PHP to the version you are using in production. If that production version is not able to run Zend Framework 2.3.1, you'd not benefit from solving the dependency problem you are experiencing.
Composer does not allow you to change the internally used PHP version if your local PHP is simply used to put together all dependencies but to used to execute these. So matching the production version is a good thing.

Problems installing PHP 5.4.11 and MySQL 5.6.10 on CentOS 6.3

I'm attempting to install PHP 5.4.11 and MySQL 5.6.10 onto a CentOS 6.3 box.
I've successfully installed PHP 5.4.11 via the remi repository for yum. I've also successfully installed MySQL 5.6.10 using the community server rpm's on the MySQL downloads page.
They both work fine independently, but when attempting to install php-mysql from the remi repository, a dependency of mysql-libs is pulled in which is at version 5.5.30, and going ahead with the install produces an array of errors like the following:
file /usr/share/mysql/czech/errmsg.sys from install of mysql-libs-5.5.30-1.el6.remi.x86_64 conflicts with file from package MySQL-server-5.6.10-1.el6.x86_64
At this point, I'm out of my depth with regards to getting this working. Can anyone suggest what I need to do to get my PHP installation working with MySQL?
rpm --nodeps --force
just override

All-in-one PHP bundle for Ubuntu

I need to deploy Zend Framework app on Ubuntu.
I've downloaded Ubuntu desktop, installed using apt-get apache+php+mysql,
but PHP turned out to be not the latest 5.3, but 5.2.1 and even
mysql extension is missing.
I understand I can get somewhere a fresh php installation, get dependent libs (like curl or libxml2) compile them one by one and then I get full-features latest PHP bundle.
But is there anywhere already full PHP bundle with latest version and all libs to get
ZF app running very quickly?
One of the downsides of package management is that you're at the mercy of the package maintainers. Ubuntu has opted not to update to PHP 5.3 in this version, so you'll have to either wait until 2010 for it or compile PHP yourself.
Most of the PHP extensions that arent in a default source build directly from PHP are in seperate apt packages. If you do a search for PHP5 in you package manager youll see packages like:
PHP5
PHP5-Mysql
PHP5-cli
PHP5-SQLite
etc..
Im going to assume that there are also packages specifically for php 5.3 - most likely labeled as php53-* or something similar. You may need to adda repo for this as im not sure its in the crore repos.
Anyhow you need to isntall all these packages that you need to use.
I ran into similar issues getting the latest PHP on my CentOS server. I installed Zend Server Community Edition, which sets up it's own Apache/PHP5.3 stack in /usr/local/zend. And here's a Getting Started article.
It's a full PHP bundle.
If you need other packages for Ubuntu, check the ubuntu repository for PHP5 at http://bg.archive.ubuntu.com/ubuntu/pool/main/p/php5/

Categories