My PHP files are not working. What is wrong?

There are several reasons that your PHP files may not be working properly. Here are the top ones and how to fix them

1. Wrong PHP version.
The main reason PHP files do not work is that you are not on a compatible PHP version. In your cPanel, search for MultiPHP. There, you can change versions to see if any work with your website. The newer the version, the better the security and performance. Some apps require older PHP versions to work or the app just needs to be updated. Once you change a PHP version, you will have to wait about 2 minutes for it to start working.

2. Misconfigured .htaccess file.
This is a little harder to troubleshoot. You'll need to remove everything from all .htaccess files in folders before your content. Normally there is only one .htaccess file you have to change. This is normally located in the main public_html folder. Once everything is removed and your site is working, you can add code back to the .htaccess file piece by piece to see what is causing the error. In some cases, you'll have to add some code back for it to work as well.

3. A bad app.
Sometimes the app you are using just has bad code or has broken. In this case, you'll need to get a new version and upload all the files over the existing ones. Just don't forget to save your database and configuration settings.

  • php, error, php.ini, php version, php error, htaccess, broken ap, broken code, php not working
  • 228 Users Found This Useful
Was this answer helpful?

Related Articles

How to flush your DNS cache

Your home computer creates a cache for all DNS settings. It does this to save time each time you...

What is the root login for my new VPS server?

The root login is the same password our system sent you in your welcome email. You just change...

What is the path to PERL?

The path to PERL in PERL script is:#!/usr/local/bin/perl

Do you troubleshoot scripts and apps?

Hello,Sorry, but troubleshooting sripts and apps needs to be done by the scipt maker or a...

How to use PHP-CLI

You would call '/usr/local/bin/php' if you need the php-cli binary, and '/usr/bin/php' if you...