www, no www and ssl checkout

Hi,

I have documents that can be accessed via a url with or without www in the header, eg www.mysite.com and http://mysite.com. I have a ssl certificate on the later, but ofcourse cookies written with the www. header are not read when the site transfers to the ssl checkout (no www)

What is the best way to recognise where the site is accessed via www and redirect to no www?

Thanks



Figured this out if anyone has same problem
'------------------------
'SET ADDRESS FROM URL
'------------------------
Dim ThisAddress
ThisAddress = Request.servervariables("HTTP_HOST")
If InStr(ThisAddress,"www") THEN
Response.redirect("http://mysite.com")
END IF
 
Back
Top