Redirect for SEO Purposes

ISAPI_Rewrite is Apache mod_rewrite compatible URL rewriter for Microsoft IIS
User avatar
Posts: 4
Joined: 18 Dec 2012, 09:14

Redirect for SEO Purposes

18 Dec 2012, 09:16

Hello,

I am finding duplicate content an issue and would like to setup a redirect. I am running v3.

So far I have a redirect for non WWW to point to WWW like this:

[ISPAI_Rewrite]

#Redirect Non WWW to WWW
RewriteEngine on

RewriteCond %{HTTPS} (on)?
RewriteCond %{HTTP:Host} ^(?!www\.)(.+)$ [NC]
RewriteCond %{REQUEST_URI} (.+)
RewriteRule .? http(?%1s)://www.%2%3 [R=301,L]

Now I would like to redirect www.mysite.co.uk/index.php to www.mysite.co.uk

Can anyone help?

If possible I would also like to know how to create 301 redirects.

Thanks in advance. :-)

User avatar
Posts: 4
Joined: 18 Dec 2012, 09:14

Re: Redirect for SEO Purposes

18 Dec 2012, 10:06

Done...
Code: Select all
[ISAPI_Rewrite]

#Redirect Non WWW to WWW
RewriteEngine on

RewriteCond %{HTTPS} (on)?
RewriteCond %{HTTP:Host} ^(?!www\.)(.+)$ [NC]
RewriteCond %{REQUEST_URI} (.+)
RewriteRule .? http(?%1s)://www.%2%3 [R=301,L]

#Redirect index.php to root
RewriteEngine on
RewriteBase /

RewriteRule ^index\.php$ http://www.aspectexhibitions.co.uk/ [NC,R=301,L]

Return to ISAPI_Rewrite 3.0

Who is online

Users browsing this forum: No registered users and 55 guests