I tried testing defender, and the moment I activated it, it

Hi,

I tried testing defender, and the moment I activated it, it broke my website.
Hardening page doesn't work.
Not only that, but even after deactivating it my website remains broken.
Even after deactivating and reactivating all plugins, I still have the issue.
Worse, even when reverting to a previous database backup I still have an issue.
And even worse, even after deleting the files related to the plugin (also in uploads) I still have the issue.

The issue is 16x Uncaught ReferenceError: jQuery is not defined

Seems my only option now is reinstall all files from a backup.
Laurent.

  • Adam Czajczyk

    Hello Laurent,

    I hope you're well today and thank you for your question!

    I'm really sorry that this went wrong for you. The error though indicates that there were some changes made in a way the JS scripts (jQuery library in this case) are being loaded. Could you please take a look at your site's ".htaccess" file and compare it against the default one?

    Here's a default .htaccess for regular WordPress install:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress

    And here's .htaccess for Multisite subfolder install:

    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    
    # add a trailing slash to /wp-admin
    RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
    RewriteRule . index.php [L]

    and subdomain install:

    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    
    # add a trailing slash to /wp-admin
    RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
    RewriteRule ^(.*\.php)$ $1 [L]
    RewriteRule . index.php [L]

    Let me know please if there are any significant differences or - in case you'd prefer that way - post your .htacces here for me so I could take a look.

    I hope we'll be able to fix that without the need to re-insteall entire site and possibly also make Defender work for you.

    Best regards,
    Adam

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.