First, let me say I'm not a DBA or network admin, but have moved large scale CMS websites from host to host. But, I have never moved a pure PHP-coded database driven website from one host to another.

What I have done is moved the entire site including the level above 'html' with the include folder with config.php, database.php, main.php etc. I have imported database(s) and have proper credentials for access.

But, when I try to load a file from the site (ex. accounts/index.html) I just get partial code returned with no css styles or anything that controls the site.

Page Output

Could someone point me in a direction to be able to start to sync this site back? Like I said, getting raw output with viewing files and can't even get CSS to load site colours and styles.

I'm a newb when it comes to this aspect of things and appreciate any guidance.


PHP is not running on your new server. Set it up correctly and be sure the database has been migrated and is working.

Try adding a simple page with:


To your webserver root folder and open it. If you do not get proper info but the script on the page the PHP scripts are not being processed.

  • I know php is running as i have a Drupal site setup up on this server as well and it is up and loading. I've also loaded a test file from the same directory as the example above with phpinfo(); and when i got it the php information is returned, so i know that php is running. Could there be anything else that comes to mind? I found it very strange as well because i have the Drupal site stood up and working. Could it possibly have to do with a php namespace or something like that? Thanks for your quick answer! Dec 7 '15 at 4:25
  • Maybe PHP is not working for that specific website. It is clear that the scripts are not being processed. I think you should migrate the question to serverfault. Dec 7 '15 at 4:26

It turns out that VirtualMin update does not parse php code inside html files "out-of-the-box". I had to remove the original .conf settings for apache and add the rule to parse php that is written inside .html files. After doing so, site loads and pulls all includes.

  • Virtualmin automatically corrects that problem on Debian/Ubuntu systems during installation. It is possible that changes to your PHP version or package may have reintroduced the configuration directive that breaks PHP execution. The default PHP configuration on Debian/Ubuntu includes directives that conflict with running PHP under fcgid/suexec. I believe running the "Re-check configuration" in Virtualmin will also identify this problem (if it doesn't, it should, and we'd want to fix it). I run CentOS on our servers, so I don't run into this problem, generally.
    – swelljoe
    Dec 15 '15 at 20:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.