RewriteEngine on
RewriteCond %{HTTP_REFERER} !^https://othersub.maindomain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^https://othersub.maindomain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^https://sub.maindomain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^https://sub.maindomain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^https://maindomain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^https://maindomain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^https://www.othersub.maindomain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^https://www.othersub.maindomain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^https://www.sub.maindomain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^https://www.sub.maindomain.com$ [NC]
RewriteCond %{HTTP_REFERER} !^https://www.maindomain.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^https://www.maindomain.com$ [NC]
# RewriteRule .*\.(jpg|jpeg|gif|png|bmp)$ – [F,NC]
# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
# uploaded files
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [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]
# END WordPress
———————–
OK this is on bluehost, and it has a main domain that is your public_html folder.
each subdomain is a folder in that folder.
You can install and copy installs of wordpress from your cpanel, i copied one i think, i am going back some time now.
so…. othersub/(in the htaccess file above) is the one that is not the one for this install.
This is also an MU (multi user) install… so, you may have multiple blogs in subfolders of your wp folder.
Mine is installed in the root of the subdomain sub/ (in the htaccess file above)
So you may only need to change the line in your .htacces file as follows:
# RewriteRule .*\.(jpg|jpeg|gif|png|bmp)$ – [F,NC]
or
if you want a MU install as well, copy other wp stuff.
You may PM me if you want more help, and i can give you my email address ??
Hope this helps for blue host ??
Shazzam