How do I redirect my site?

To make a 301 redirect for a changed page, you need to add the following into a .htaccess file

redirect 301 /old page name your.domain.com/new page name 

So for example, if you wanted to redirect www.oldsite.com/smith.html to www.oldsite.com/jones.html, you would put 

redirect 301 /smith.html http://www.oldsite.com/jones.html 

To prevent google being confused about your site (Is it http://yourdomain.com or http://www.your.domain.com 

Just add the following to a .htaccess file 

RewriteEngine On 
RewriteCond %{HTTP_HOST} ^mywebsite.com 
RewriteRule (.*) http://www.mywebsite.com/$1 [R=301,L] 

This will cause anyone who uses mywebsite.com to be automatically redirected to www.mywebsite.com 

  • 0 A felhasználók hasznosnak találták ezt
Hasznosnak találta ezt a választ?

Kapcsolódó cikkek

Do you support SSI (Server Side Includes)?

Yes we do. SSI (Server Side Includes) are tags that are placed in HTML pages, and evaluated on...

How can I change the file name extension of my index page?

It is possible to name your default index page something other than index.html, index.cgi,...

How can I enable directory indexing

If you want to see a list of files in a directory when viewing it in a browser rather than a web...

How can I force a particular charset? (Character Encoding)

You are able to set a default value for the media type charset parameter (the name of a character...

How do I edit php.ini (PHP settings) for my hosting package?

Becuase of the way in which we run PHP, you are able to customise its behaviour with php.ini...