Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

https to http - backwards huh

Discussion in 'General Discussion' started by t9clkclnr, Apr 6, 2005.

  1. t9clkclnr

    t9clkclnr Well-Known Member

    Joined:
    Jun 11, 2004
    Messages:
    254
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Southern California
    I want to make users who access this:

    https://www.mydomain.com

    to be redirected to this:

    http://mydomain.com

    I do have code on my index page that checks HTTPS and will redirect but it;s not happening before the headers are sent to the server and the 401 auth error is returned telling users the SSL cert name does not match.

    how can i redirect the users to the non-secure site immediatley before the 401 is issued to the client?

    thank you.
     
  2. t9clkclnr

    t9clkclnr Well-Known Member

    Joined:
    Jun 11, 2004
    Messages:
    254
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Southern California
    one more thing...

    access to anthing in the root of mydomain.com should not be allowed to access the site via https

    i want to only allow https access to subfolder pages.
     
  3. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,460
    Likes Received:
    21
    Trophy Points:
    463
    Location:
    Go on, have a guess
    You cannot do this in a html file as the act of connecting via SSL sets up the encrypted connection.

    You might be able to do it in either a .htaccess file or within the domains VirtualHost container for the 443 port using a mod_rewrite rule - but without testing it, I somehow doubt that it would work that way either.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. Kerstin

    Kerstin Well-Known Member

    Joined:
    Apr 9, 2005
    Messages:
    136
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Berlin
    Your link t9clkclnr are interested :) for unsecure the https encryption to the forum ;)
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice