Re: Re: very strange session behavior -- fails on port 80, works on 9090

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



okay... well, i checked that and it looks like:

<VirtualHost x.x.x.x:80>
   ServerName  examplemotion.com
   ServerAlias www.examplemotion.com
.......

<VirtualHost x.x.x.x:443>
   ServerName  examplemotion.com
   ServerAlias www.examplemotion.com

so, i changed both ServerNames to www.examplemotion.com, and commented
out the ServerAliases, restarted HTTPD, and still end up with the same
behavior.

fwiw, this is the first bit of logic that is hit when arriving at the
chekout page, and thus the final redirect to the search page on the
port 80 version:
// if sum of docs is 0, redirect
if (!MyFunctions::getTotalAmountInCart()) {
	QApplication::Redirect('/search/');

also, the context switch to https from http happens as soon as you hit
the cart, and that also switches the domain.  so, if you manually put
the 'www' back into the url, click on the cart, and then checkout, all
works well.

soooo.... i just need to find out where the protocol is being
switched, and why that causes a switch in the domain.  any input you
(or anyone) has on this is very much appreciated!  thank you!!!

--fjs--


On Fri, Mar 20, 2009 at 11:03, Shawn McKenzie <nospam@xxxxxxxxxxxxx> wrote:
> francisco j sanchez wrote:
>> Shawn,
>>
>> thank you so much for your reply.  I think this definitely has me on
>> the right track.  what i need to figure out now is, is it Apache or
>> PHP that is switching the domain?  all the code uses relative links
>> (as far as i can tell... i didn't build this project, i inherited it,
>> so i'm figuring out the code as i go along).  Like I said in my
>> original post, I actually have 80 & 9090 pointed to the same dir on
>> the filesystem, and the same db.  However, as you so astutely pointed
>> out, the 9090 version doesn't switch to SSL, and I'm guessing that has
>> to do with our SSL cert?  I'm not sure what part of the code handles
>> that switch, but am currently digging through that.
>>
>> Do you know if there's a way for PHP to set cookies for
>> *.mydomain.com?  In other words, have a cookie be valid for all
>> subdomains across a domain?  Or, do you have any input on where/who
>> might be switching the domain (apache, php, client-side?)?
>>
>> Thanks again!
>>
>> --fjs--
>
> The problem is most likely in your Apache config, either virtualhosts or
> a rewrite rule.  Look in your httpd.conf or equivalent for the
> <VirtualHost x.x.x.x:80> and <VirtualHost x.x.x.x:443> and compare the
> ServerName parameters.  Just a guess, but I would assume that it looks
> similar to this currently:
>
> <VirtualHost x.x.x.x:80>
>    ServerName  www.examplemotion.com
>
> .......
>
> <VirtualHost x.x.x.x:443>
>    ServerName  examplemotion.com
>
> Which should be the same for both I think.
>
> --
> Thanks!
> -Shawn
> http://www.spidean.com
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>



-- 
francisco j sanchez

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux