security – htaccess if requested url is /wp-admin
Question
I need some help with my .htaccess.
I want this lines only execute if the url is not /wp-admin.
Header add Content-Security-Policy "default-src 'self';"
Header add Content-Security-Policy "script-src 'self';"
My idea was something like this:
<If "%{REQUEST_URI} !^/wp-admin">
</If>
<Else>
Header add Content-Security-Policy "default-src 'self';"
Header add Content-Security-Policy "script-src 'self';"
</Else>
Maybe it would be nice if a loggedin user is on the website that the lines also not be executed.
Thank you for the help.
0
2 weeks
2022-06-21T06:42:03-05:00
2022-06-21T06:42:03-05:00 0 Answers
0 views
0
Leave an answer