Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

So, I have two websites setup through 1and1 hosting. One, apparently needs php4 the other apparently needs php5.

The site that is priority requires php4; the other php5. When I switch them, one of the sites break in response. The php4 site's menu is destroyed and displays code and ugly errors in it's place, the other is broken by when you attempt to 'click' anything with the Wordpress Control panel (ie; Click 'posts' and get an error 500).

Anyone know what to do?

share|improve this question

migrated from stackoverflow.com Aug 16 '11 at 0:44

This question came from our site for professional and enthusiast programmers.

    
If code is being displayed when you switch versions, it sounds like the PHP5 config has short_tags disabled while the PHP4 config has them enabled. The fix for that is to just replace <? with <?php in the code -- an easy change. –  Dan Grossman Aug 13 '11 at 23:44

1 Answer 1

Rewrite the code to work with PHP5 or put the sites on separate hosting. PHP 5 is now over 7 years old. You should not expect to be able to continue hosting that PHP 4 site anywhere much longer.

share|improve this answer
    
I agree with Dan above, rewrite the code or you are going to run into more problems sooner rather than later. –  Ryan Aug 14 '11 at 2:50

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.