WebSite X5Help Center

 
Vitaly Semenov
Vitaly Semenov
User

Redirect traffic from the address www on the address non www  en

Autor: Vitaly Semenov
Visitado 1034, Followers 1, Compartido 0  

Hello.
I have added your site to Google webmaster.com. He is there in the two kinds of addresses www.vitsem.com and vitsem.com. Tell me how can I check that they do not work as the two sites. I want all traffic going to vitsem.com. How do I do this? And how can I check that it is need? 
Thank you very much.

Publicado en
1 RESPUESTAS - 1 ÚTIL - 1 CORRECTO
Paul M.
Paul M.
Moderator

Hello Vitaly,

Put the following code inside your .htaccess file in the root folder of your X5 project on your web server:

#Redirect www to non-www
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} ^www.vitsem.com [NC]
RewriteRule ^(.*)$ http://vitsem.com/$1 [L,R=301]

This will ensure that each and every page which a visitor requests is directed to the non-www version.

The redirect as above is permanent, and as such should not affect your search engine ranking.

Kind regards,

Paul

Leer más
Publicado en de Paul M.