Issue with rewrite rule on Litespeed webserver

[ad_1]

Hi everyone,

My former hosting party uses Apache only, and the following rewrite rules in the .htaccess works fine (just for testing purpose!):

RewriteEngine On
RewriteCond %{HTTP\_COOKIE} !.\*wordpress\_logged\_in.\*$ \[NC\] RewriteCond %{REQUEST\_URI} \^(.\*?/?)wp-content/uploads/.\* \[NC\] RewriteRule . https://%{HTTP\_HOST}%1/not-available \[L\]

My new hosting party is using Lightspeed webservers, and I can’t get this to work, Litespeed claimes it’s fully compatible with Apache .htaccess rewrite rules, but I’m stuck here.

What is it I’m doing wrong, or do not understand?

[ad_2]
1 Comment
  1. Yikes – why do you want to block uploads from anon users? That will include Google as well you realise?

    Don’t use it. That’s pretty hacky.

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer