How to install php5.5 on ubuntu 16.0.04 - php

I am new to Ubuntu, using version 16.0.04. I am trying to install php5.5. after installation it show php5.6 when running the command php -v.
Help me to install php5.5 on Ubuntu 16.0.04
I want to run symfony framework, In PHP7.0 it get error.

Your post is not clear.
Read From this post :
https://askubuntu.com/questions/849808/installing-php5-5-on-ubuntu-16-with-apache2
The PHP 5.5 have been removed from ppa:ondrej/php, the lowest version is php5.6. Note that there are differences between php5.5 and php5.6, so you need to test your code. There is a major difference with object serialisation.

Related

Linux add PHP 7.4 to Webmin/Virtualmin

My current setup of Webmin/Virtualmin has PHP 5.6 and 7.2. More and more composer packages have a requirement of PHP 7.4. I don't want to have 7.4 as the default PHP, I have sites on the server that need 5.6 (I know, not great but it's the way it is), so I'm trying to get 7.4 installed in the same structure as 7.2, in the /opt/rh folder.
The version of Linux is "CentOS Linux release 7.8.2003 (Core)"
I've tried to do this about 5 times and failed each time, there is just no information (that I can find) out there to say how to do this. Any help would be massively appreciated.
If you need to keep default version of PHP, make sure to install PHP 7.4 from [remi-safe] repos.
Install Remi Release repo and clear cache:
yum -y install http://rpms.remirepo.net/enterprise/remi-release-7.rpm && yum clean all
Install PHP 7.4 packages:
yum -y install php74-php-{cli,pdo,fpm,zip,gd,xml,mysqlnd}
It's clearly described in our documentation page on how to install different versions of PHP for Virtualmin.
You can have couple version of php running in the same time.
Check this
Multiple PHP Version on Centos

installing Mcrypt php extension fails on Ubuntu and Xampp

I installed Xampp on Ubuntu 16 to work with Laravel.
I ran my Laravel code and got this error : Mcrypt PHP extension required.
After that I tried to install Mcrypt on PHP.
I have done these :
sudo apt-get install mcrypt
sudo phpenmod mcrypt
I have also done this : Link
I also restart the all services from Xampp after every change but I still get error on Laravel.
Any idea ?
My PHP version is 7.0.22 and Ubuntu version is 16.04.1 .
Thank you .
Edit 1
I did this and I still see the error.
After trying to many things. I just got rid of this shit by installing both version on my computer.
First I installed php 7.1.19 version.
Secondly I installed php 7.2.15 version
Now I am working perfectly with my project.

Cloud 9: PHP7 cURL not working

Not sure why this isn't working in c9... but
It's really strange because i have installed php5-curl, but i do have php7.0.9, is there a php7-curl?
I have tried apt-get php-curl, php7-curl, php7.0-curl.... and none of them work.
All I get is:
E: Unable to locate package php70-curl
for all of them.
I also updated apt-get.....
SO am i missing something?
PHP 5 extensions do not work with PHP 7. As far as I know, if you compile PHP 7 with --with-curl in the configure command, it will just compile it in.
Are you running Ubuntu? If you are, then are you running 16.04 or newer? In 16.04, there's a package called php7.0-curl in the Ubuntu repositories. http://packages.ubuntu.com/xenial/php7.0-curl
If you are on Ubuntu and on a release earlier than 16.04, I would suggest upgrading. If you are not on Ubuntu, then which distribution are you on?
EDIT: After creating an account on Cloud9, I found that the PHP template is running Ubuntu 14.04 with PHP 5.5. Did you change this?

Orange HRM is not Working for PHP 7

I updated my server from PHP 5.5 to PHP 7. Now Orange HRM is not Working.
Production is on hr.oyasys.com . Error happen only after login (http://hr.oyasys.com/index.php/dashboard)
stack trace
at ()
in SF_ROOT_DIR/lib/vendor/symfony/lib/controller/sfController.class.php line 182 ...
if ($this->getActionStack()->getSize() >= $this->maxForwards)
{
// let's kill this party before it turns into cpu cycle hell
throw new sfForwardException('Too many forwards have been detected for this request.');
}
I don't think OrangeHRM has accounted for updates to PHP 7. mysql_* functions were also removed and I ran into an error or install.
https://wiki.php.net/rfc/remove_deprecated_functionality_in_php7
OrangeHRM uses the legacy mysql_connect extension which was deprecated in PHP 5.5 and was completely removed from PHP 7.
If you need to run OrangeHRM, you will have to downgrade your PHP version to 5.x or move OrangeHRM to a different compatible server.
I solved in this way to install orangehrm 3.3.0 on ubuntu 16.04
Added PPA repository
sudo add-apt-repository ppa:ondrej/php
Installed php5.6
sudo apt-get update
sudo apt-get install php5.6
Installed some modules
sudo apt-get install php5.6-mbstring php5.6-mcrypt php5.6-mysql php5.6-xml
Enabled php 5.6 module in apache2
Installation works fine
Downgrading is not really solving the issue, it's just working around the issue. There are a lot of people that cannot simply downgrade due to restrictions with other software running, and in some cases, IT policy.
It sucks, but we're not getting any love or a real solution until OrangeHRM does the changes necessary to support being run under PHP 7.

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

Categories