How can one run multiple versions of PHP 5.x on a development LAMP server?

With CentOS, you can do it using a combination of fastcgi for one version of PHP, and php-fpm for the other, as described here: https://web.archive.org/web/20130707085630/http://linuxplayer.org/2011/05/intall-multiple-version-of-php-on-one-server Based on CentOS 5.6, for Apache only 1. Enable rpmforge and epel yum repository wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el5.rf.x86_64.rpm wget http://download.fedora.redhat.com/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm sudo rpm -ivh rpmforge-release-0.5.2-2.el5.rf.x86_64.rpm sudo rpm -ivh epel-release-5-4.noarch.rpm 2. Install php-5.1 CentOS/RHEL … Read more

Why use deflate instead of gzip for text files served by Apache?

Why use deflate instead of gzip for text files served by Apache? The simple answer is don’t. RFC 2616 defines deflate as: deflate The “zlib” format defined in RFC 1950 in combination with the “deflate” compression mechanism described in RFC 1951 The zlib format is defined in RFC 1950 as : 0 1 +—+—+ |CMF|FLG| … Read more

How do I change the root directory of an Apache server? [closed]

Please note, that this only applies for Ubuntu 14.04 LTS (Trusty Tahr) and newer releases. In my Ubuntu 14.04 LTS, the document root was set to /var/www/html. It was configured in the following file: /etc/apache2/sites-available/000-default.conf So just do a sudo nano /etc/apache2/sites-available/000-default.conf and change the following line to what you want: DocumentRoot /var/www/html Also do a … Read more