essah77
Forum Replies Created
-
The situation has changed a little bit:
Root: https://watercolorpainting.com/
Root WP install (moved from subdomain): https://watercolorpainting.com/staging
Second WP install: https://watercolorpainting.com/watercolor-painting-tutorialsThis is the .htaccess (rewrite rules) from https://watercolorpainting.com/staging:
<IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] RewriteCond %{HTTP_HOST} ^staging.watercolorpainting.com RewriteRule ^(.*)$ https://watercolorpainting.com/staging/$1 [L,NC,QSA] </IfModule>
This is the .htaccess (rewrite rules) from https://watercolorpainting.com/watercolor-painting-tutorials/:
<IfModule mod_rewrite.c> RewriteEngine On RewriteBase /watercolor-painting-tutorials/ RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /watercolor-painting-tutorials/index.php [L] </IfModule>
I understand, that we have a conflict between the rewrite rules in both installations.
My question is: Is it possible to say the these URLs (…/watercolor-painting-tutorials/) belongs to this installation (…/watercolor-painting-tutorials/) in the .htaccess file of https://watercolorpainting.com/staging ?
Thank you James and bestwebsoft for your answers. I tried it. It doesn′t work. Maybe I′ve done it wrong. Can you please post me the exact code and tell me in which directory/ .htaccess I should add the rewrite rules?
Btw: we′re using https://www.cloudflare.com/. Is there any possibility to solve this problem?
Thank you for answering.
-
I have changed the Site Address (URL) in WP Backend from https://watercolorpainting.com/watercolor-painting-tutorials in https://watercolorpainting.com.
I have added your RewriteRule in the .htaccess of the “root” folder “/staging/” where a WP installation is running on (actually from a subdomain https://www.staging.watercolorpainting.com):
</IfModule>
# END W3TC Browser Cache
# 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] RewriteCond %{HTTP_HOST} ^(www.)?watercolorpainting.com$ RewriteRule ^(/)?$ watercolor-painting-tutorials [L] </IfModule>
Now I get a 404 page on: https://watercolorpainting.com/watercolor-painting-tutorials/ (because I changed the Site URL). Your ReqriteRule doesn′t have any impact.
What′s next? Thank you!