[top posting out of spite] ;-)
I'm guessing that the OP is only dealing with 1 domain?
why not...
...only single quotes for extra speed :-) and no extraneous $newurl var either.
John Nichel wrote:
Ross wrote:
now.
I am using the following code to turn http into https and get my ssl
wo
People have fun with the oddest things ;)
Anyway, it's a nice reference to have around :)
On 6/29/05, Philip Hallstrom <[EMAIL PROTECTED]> wrote:
> > OK OK I got it ;)
> >
> > I just suggested it because I thought he could assume that "www."
> > would always be on the string.
> >
> > Either way,
OK OK I got it ;)
I just suggested it because I thought he could assume that "www."
would always be on the string.
Either way, I guess _one_ preg_replace is alright.
Heh :-) Just for kicks...
- randomly prefix "www." onto 1324 proper names (dictionary file). 659 end
up with "www." prefixed.
OK OK I got it ;)
I just suggested it because I thought he could assume that "www."
would always be on the string.
Either way, I guess _one_ preg_replace is alright.
On 6/29/05, Kevin L'Huillier <[EMAIL PROTECTED]> wrote:
> > > Wouldn't
> > >
> > > $newUrl = 'https://' . substr( $_SERVER['SERVER
> > Wouldn't
> >
> > $newUrl = 'https://' . substr( $_SERVER['SERVER_NAME'], 4 )
> >
> > be a _hell_ of a lot faster?
>
> If one considers micro-seconds 'a _hell_ of a lot faster', then _maybe_
And it could be slower if you avoid sending someone from
http://example.com/ to https://ple.co
On Wed, 2005-06-29 at 10:57 -0700, Philip Hallstrom wrote:
I am using the following code to turn http into https and get my ssl
working.
if($HTTP_SERVER_VARS["HTTPS"] != "on")
{
$newurl = "https://"; . $_SERVER["SERVER_NAME"] . $_SERVER["REQUEST_URI"];
header("location: $newurl");
}
$newurl
André Medeiros wrote:
$newurl = "https://"; . ereg_replace("^www.", "", $_SERVER["SERVER_NAME"])..
Wouldn't
$newUrl = 'https://' . substr( $_SERVER['SERVER_NAME'], 4 )
be a _hell_ of a lot faster?
If one considers micro-seconds 'a _hell_ of a lot faster', then _maybe_
--
Jo
On Wed, 2005-06-29 at 10:57 -0700, Philip Hallstrom wrote:
> > I am using the following code to turn http into https and get my ssl
> > working.
> >
> > if($HTTP_SERVER_VARS["HTTPS"] != "on")
> > {
> > $newurl = "https://"; . $_SERVER["SERVER_NAME"] . $_SERVER["REQUEST_URI"];
> > header("location
Ross wrote:
now.
I am using the following code to turn http into https and get my ssl
working.
if($HTTP_SERVER_VARS["HTTPS"] != "on")
{
$newurl = "https://"; . $_SERVER["SERVER_NAME"] . $_SERVER["REQUEST_URI"];
header("location: $newurl");
}
However I set the ssl up on http://mydomain.
I am using the following code to turn http into https and get my ssl
working.
if($HTTP_SERVER_VARS["HTTPS"] != "on")
{
$newurl = "https://"; . $_SERVER["SERVER_NAME"] . $_SERVER["REQUEST_URI"];
header("location: $newurl");
}
$newurl = "https://"; . ereg_replace("^www.", "", $_SERVER["SERVER_N
10 matches
Mail list logo