Not sure if all this is clear to you, but let me know if it is not :)
Kli
For simple cli testing cli you can simply install each version in your own folders, for example. /usr/local/php-5.4/bin , /usr/local/php-5.3.10/bin , etc.
Fastcgi
You can run PHP in FastCGI mode for some time. You can let several versions work at the same time and bind them to different ports, for example. :9000 :9001 :9002 , etc.
The next step is to create several virtual hosts based on the names in Apache, Nginx, Lighttpd or Node.js. Each virtual host associates with a different FastCGI process and therefore uses a different version of PHP.
Jaอขck
source share