Forum

301 redirect question

Fred
7 July 2015, 13:52
Hi Hugo,

We have created a brand new website to replace an old one for a customer.

So far everything is working just fine but we have a problem with SEO.

As far as goggle ranking goes, we will lose around 240 hyper-link has they have changed in the new site.
In the past, when using Apache, we simply created a permanent uestion via .htaccess

Could you please tell me how this can be achieve in Hiawatha?

Thank you
Fred
7 July 2015, 14:31
Here is an example of what I normaly use in my .htaccess file
Redirect 301 / http://mydomaine.com/
Redirect 301 /auberge-au-vieux-pressoir/ http://mydomaine.com/auberge-au-vieux-pressoir/
Redirect 301 /boutique/ http://mydomaine.com/boutique/
Hugo Leisink
7 July 2015, 14:41
Two options you can look at: the ErrorHandler (use for 404 errors), which can be used to capture all requests to non-existing files (and let some CGI handle the correct response) or the redirect option of the UrlToolkit (which uses 301 in the response).
Fred
7 July 2015, 14:56
Hi Hugo,

Sorry to be a pain but could you give a simple example using toolkit
Hugo Leisink
7 July 2015, 14:58
Pas de problem.
UrlToolkit {
ToolkitID = redirect_old_urls
Match ^/$ Redirect http://mydomaine.com/
Match ^/auberge-au-vieux-pressoir/$ Redirect http://mydomaine.com/auberge-au-vieux-pressoir/
Match ^/boutique/$ Redirect http://mydomaine.com/boutique/
}
Fred
15 July 2015, 10:56
Merci Beaucoup Hugo
Xaris
16 July 2015, 18:19
Hi there,


I want to 301 redirect the following:

http://www.example.com/folder-name1/ to http://www.example.com/folder-name1/index.php/folder-name2/

Is that possible with htaccess?

Which code should I use

Thanks in advance


This topic has been closed.