Hello,
"1LT John W. Holmes" <[EMAIL PROTECTED]> wrote:
> > OK. I think I understand this, but let me ask just to be sure.
> >
> > So if I setup in my page something to this effect:
> > if ($_SERVER['!HTTPS']) {
> > echo "Switching over to SSL...";
> > echo "<META redirect to SSL>";
> > } else {
> > echo "**Rest of Page**";
> > }
> >
> > Would this work? I am about to add a secind site to my site using an
alias
> > in Apache. Example is http://www.mysite.com for first site and
> > http://www.mysite.com/2ndsite. Except I want everything for the second
> site
> > to be https. Make sense?
>
> if(!isset($_SERVER['HTTPS']))
> { header("Location: https://www.mysite.com/2ndsite"); }
>
> That should work. Or you could echo the META redirect if you wanted to
> display a page, but this should do it transparently. There is probably a
way
> to do it with just Apache, too, that wouldn't involve PHP.
I think there's some useful info here (about doing it with "just Apache"):
http://httpd.apache.org/docs-2.0/ssl/ssl_howto.html
Just in case...
- E
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php