1and1.com and php 4.0 / 5.0
Today, I learned that 1and1 has a bit of a goofy issue concerning the version of php that is installed on their servers.
You see they have somehow achieved both php 4.0 and 5.0 installations. This poses an issue when it comes to Joomla! because it automatically uses the php 4.0 installation and this poses security risks that Joomla! has either fixed or doesn’t need to worry about if php 5.0 were installed and being utilized.
Luckily there’s a fix and it’s simple!
Go into your Joomla! root directory and find the htaccess.txt file. Download it to your computer and open it with either notepad or wordpad. Scroll to the bottom of the document and paste the following…
########## Begin php fix
#
AddType x-mapp-php5 .php
#
########## End php fix
This code will add a mime-type which tells any php file that is loaded by the server to be executed using php 5.0. Seeing as how 1and1 has both 4.0 and 5.0 installed, their servers are able to do this.
Next upload the file back to the Joomla! directory via FileZilla (or your FTP Client of choice), but be sure to rename the file to .htaccess on the server, otherwise the server won’t utilize it.
To double check that the changes were made, go to your Joomla! admin panel. Under Help > System Info check the php version to see if it’s 5.x.x. Then proceed to the php Information tab and look for registered_globals and make sure it’s off. If both of these are present then your correction worked, and Joomla! should be both more secure and less likely to cause errors.
Congrats you just made your Joomla! world a better place!
Excellent description of how to solve this problem with PHP.
OH GOD THIS PROBLEM. this was the highlight of last semester for me: discovering that 1and1 was running 4.0 when they could be using 5.0?
thank you so much for a clear and concise summary how to fix this issue.