• Resolved bracked

    (@bracked)


    I’m trying to activate extended protection, and I can’t seem to get past the page that tries to set auto_prepend_file in php.ini. No matter what I try I get the error “The changes have not yet taken effect. If you are using LiteSpeed or IIS as your web server or CGI/FastCGI interface, you may need to wait a few minutes for the changes to take effect since the configuration files are sometimes cached. You also may need to select a different server configuration in order to complete this step, but wait for a few minutes before trying. You can try refreshing this page.”

    When I go to Tools > Diagnostics > Click to view your system’s configuration in a new window, I actually see that auto_prepend_file is set correctly, but Wordfence seems to not be seeing it. I am hosting on Siteground.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter bracked

    (@bracked)

    After some investigation I found I needed to add a line to my .htaccess file:

    SetEnv PHPRC /<PATH_TO_WEBSITE_ROOT>/php.ini

    The problem though, is when this directive is enabled I get php errors appearing on the site, and some parts of the admin panel stop working.

    Any ideas?

    • This reply was modified 7 years, 2 months ago by bracked.
    Thread Starter bracked

    (@bracked)

    Looks like the issue was running php 7.x. Rolling back to 5.6 fixed the problem.

    Hi,
    Wordfence is fully compatible with PHP 7.x, may I ask if you followed the guidelines documented here precisely? notes there are specifically written for SiteGround.

    Thanks.

    Thread Starter bracked

    (@bracked)

    Yes, I followed those steps specific to siteground. After I set the variable for auto_prepend_file it would appear correctly set but did nothing until I added the PHPRC line. Once I added the PHPRC line extended protection became enabled but I had multiple PHP errors appearing on my site and I couldn’t access certain Admin panel areas like plugin configuration and editing posts. A Tier 3 Siteground support person rolled my site back to PHP 5 and all the errors cleared up instantly.

    In hindsight I don’t know the root cause, but after a few days of troubleshooting I’m glad it’s behind me.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Trouble Activating Extended Protection’ is closed to new replies.