I use IIS and did this sitewide by moding the 403.4 error page in IIS.
 I added this to the 403.4 error template

<SCRIPT LANGUAGE="JavaScript">
if (location.protocol != 'https:'){
     window.location= 'https://' + location.host + location.pathname +
location.search
}
</SCRIPT>

Doug


On Tue, 23 Nov 2004 23:38:03 -0700, Jim McAtee <[EMAIL PROTECTED]> wrote:
> You'll probably also want to append the query_string (url variables).
> 
> <cfif cgi.server_port neq 443>
>   <cfset redir = "https://"; & cgi.http_host & cgi.path_info>
>   <cfif Len(cgi.query_string)>
>     <cfset redir = redir & "?" & cgi.query_string>
>   </cfif>
>   <cflocation url="#redir#">
> </cfif>
> 
> 
> 
> 
> ----- Original Message -----
> From: "Patricia Lee" <[EMAIL PROTECTED]>
> To: "CF-Talk" <[EMAIL PROTECTED]>
> Sent: Tuesday, November 23, 2004 11:10 PM
> Subject: Re: Force use of HTTPS
> 
> > Would this help?
> >
> > <cfif cgi.SERVER_PORT NEQ "443">
> >  <cfset redir = 'Https://' & HTTP_HOST & PATH_INFO>
> >  <cflocation url="#redir#" addtoken="No">
> > </cfif>
> >
> >> Hi again - how do I force hte use of HTTPS pages ? I can force the flow
> >> of
> >> pages with <cflocation> tags, but I want to stop a user just typing in
> >> the
> >> URL as HTTP ? Thanks
> >>
> >
> >
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Special thanks to the CF Community Suite Gold Sponsor - CFHosting.net
http://www.cfhosting.net

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:185304
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to