views:

37

answers:

2

I have XAMPP with PHP 5.2, but my new projects need PHP 5.3 How to have PHP 5.2 and 5.3 together?

I have winXP.

A: 

You've two choices: run two servers on a different port, or use CGI.

You can get XAMPP with PHP 5.3.1 here: http://www.apachefriends.org/en/xampp-windows.html#641 Edit \xampp\apache\conf\httpd.conf, and change Listen to Listen 8080 for example. Then run \xampp\apache_start.bat to start that server instance. Optionally, change DocumentRoot to your project directory.

Lekensteyn
A: 

You can do one of the following:

  • Ensure your older apps can run on 5.3 while not using 5.3 specific features. This is probably the best route as it will tighten your code and it will run on more platforms, especially in the future when more production environments use 5.3 only.

    If this is for development purposes only you can also consider:

  • multiple installations of XAMPP and switch between them when necessary via simple folder rename (somewhat tedious)

  • php-switch (very tedious)

  • setup two apache servers on the same machine running different PHP versions

webbiedave