There is no upgrade between PHP4 and PHP5, You'll just have to install PHP5. To do it on Linux, either:
- You try to find out an RPM package and you just install it like this
rpm -i name_of_your_package
- Either you download the PHP5 source files and you compile it/build youself.
In the 2nd case, you'll have to proceed to 3 stages:
- configure (do a ./configure --help) to see all the available options
- Make sure you dispose of the libiconv, gettext libraries. If you need simpleXML support, make sure you've got libxml2. By default, the configure script will try to use the zlib library. If you don't need it, just specify --without-zlib .
So, your configure command should look like
./configure --with-apxs[2]=[path to apache] --enable [what_ever_feature_you_would_require] --with-regex=system [--without-zlib]
apxs for apache 1.3 and apxs2 for apache2
after that, just perform a make and then make install.