admin.php file being downloaded after website migration

Home Forums BulletProof Security Pro admin.php file being downloaded after website migration

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #38608
    Petrus
    Participant

    Cloned my site and followed the migration guide.

    I am unable to access custom code etc. It downloads admin.php every time I try to click on it in the menu.

    #38610
    AITpro Admin
    Keymaster

    If the admin.php file is being downloaded installed of loaded/processed then the php/php.ini handler htaccess code in your root htaccess file is either invalid or missing for this web host or this web host does not require php/php.ini handler htaccess code. Did you clone your site to a new web host? If so, which web host is the site cloned to?  Try doing the steps below and let me know what happens.

    https://forum.ait-pro.com/forums/topic/php-file-download-when-accessing-site/#post-37792

    1. Use FTP or your web host control panel file manager and rename the /bulletproof-security/ plugin folder to /_bulletproof-security/.
    2. Login to your web host control panel and check the PHP version that your website is currently using.
    3. Edit your Root htaccess file and add the correct php/php.ini handler htaccess code for your PHP version. Delete any other php/php.ini handler htaccess code that you find in your Root htaccess file.
    4. See if you can now login to your website go to the WordPress Plugins page and click the Must-Use link at the top of the Plugins page.  If AutoRestore is turned Off you will see – “AutoRestore is turned Off” in green font under the BPS Pro MU Tools must-use plugin.  If AutoRestore is not turned Off then click the “Turn Off AutoRestore” link.
    5. Rename the /_bulletproof-security/ plugin folder back to /bulletproof-security/.
    6. If you can login to your website then go the BPS Pro Quarantine page and check if files have been quarantined or not and let me know that in your forum reply.
    7. Copy the new php/php.ini handler htaccess code that you added to your Root htaccess file to this BPS Root Custom Code text box:  1. CUSTOM CODE TOP PHP/PHP.INI HANDLER/CACHE CODE
    8. Click the Save Root Custom Code button.  Note: If your web host has ModSecurity CRS installed and you are unable to save your Custom Code then click the Encrypt Custom Code button first and then click the Save Root Custom Code button.

    #38612
    AITpro Admin
    Keymaster

    Instead of doing steps #2 and 3 above just delete your root htaccess file. Then go to step #4.

    #38613
    Petrus
    Participant

    Starting to slowly understand the BPS mechanics. It’s impressive.

    The old site we cloned from uses php73, the new site we cloned to only goes to php72

    Old site
    AddHandler application/x-httpd-ea-php73 .php .php7 .phtml

    New site
    AddHandler application/x-httpd-ea-php72 .php .php7 .phtml

    I found it earlier and turned BPS off, made the change in root and security.htaccess and turned BPS back on, but of course it just deleted it. I turned autoresore off, added it again in htaccess manually and then was able to add it in BPS custom code as the handler. Everything is happy happy happy again. Well so far lol

    #38615
    AITpro Admin
    Keymaster

    You figured out one of the most, if not the most, difficult issues/problems that can occur when cloning/migrating a website. Great job!

    #38617
    Petrus
    Participant

    Yea thanks to world class support. It’s legendary!!@

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.