index.php is get downloading
Why index.php is downloading? You wanna know that.
The issue occurred due to PHP handler and the rule in.htaccess file.
How to fix?
Step 1. Go to cPanel change your domain’s PHP version to 5.6
Step 2. Login as root via SSH
Step 3. Go the home folder of the user
Step 4. find . –name .htaccess
You could see some .htaccess file, open it via any editor like nano or vim
You can see something like this in the .htaccess file
AddHandler application/x-httpd-php52 .php <IfModule mod_suphp.c> suPHP_ConfigPath /opt/php52/lib </IfModule>
Uncomment the AddHandler or change the name of.htaccess file to .htaccess_bak
Step 5. Clear your browser cache and recheck it