- You are on OS X and have the latest XAMPP installed with PHP 5.3
- Download xampp-macosx-1.0.1.dmg from Sourceforge; this includes PHP 5.2.9
- Copy existing /Applications/XAMPP/xamppfiles/modules/libphp5.so to /Applications/XAMPP/xamppfiles/modules/libphp53.so
- Open the DMG and copy its xamppfiles/modules/libphp5.so to the same directory in your install's modules directory, but give it the name libphp52.so
- From the DMG, copy xamppfiles/lib/libming.0.3.0.dylib to your xamppfiles/lib/ directory.
- From the DMG, copy xamppfiles/lib/php/php-5.2.9 into your xamppfiles/lib/php/ directory to live alongside php-5.3.x
- From the DMG, copy the xamppfiles/bin/php*5.2.9 files to your xampp/bin/ directory, to live slongside their PHP 5.3 equivalents.
- Then you can switch between PHP 5.2 and PHP 5.3 by swapping out the modules/libphp5.php file and restarting Apache, as demonstrated in the included scripts.
So far, things are working for me.