Answer the question
In order to leave comments, you need to log in
Understand mod rewrite?
There is a link structure:
sitename.ru/glavnaya/portfolio
sitename.ru/glavnaya/portfolio/site1
How to remove glavnaya?
What should be written in .htacces?
Answer the question
In order to leave comments, you need to log in
I would do it like this:
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*) sitename.ru/glavnaya/ $1 [L]
Do you write under some kind of engine, or with your hands?
Everything that interests you is done, for example, like this:
Redirect 301 /d/file.html www.domainname.com/r/file.html
And here is a good site that fully reveals the possibilities of .htacces
www.proofsite.com.ua/ article-2242.html
checked, plows:
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_URI} !^/glavnaya/
RewriteRule ^(.*)$ /glavnaya/$1 [PT,QSA]
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question