Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / How to return to product page after login?

How to return to product page after login?

Locked

Views: 4,419

Results 21 to 26 of 26
This thread is locked. New replies are disabled.
9 Sep 2007, 4:45 AM
#21
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

How to return to product page after login?

dbabbage:

The site has only recently been launched so we have limited information to go on. However, Safari was the primary browser used in all site testing, except for that specifically focussed on cross-browser compatibility issues. In that time we did not experience a single lost login, cart getting emptied, or order that could not be completed. This was also nearly all on the "live" server that is now causing this problem, since it was on a new domain and hidden behind a splash screen. The offline install was only established when the main site was officially launched.What exactly is the current symptom ?
Is it losing the login when clicking "login for price" links on product pages?
or is it just not remembering to go back to product pages, but has successfully logged in?

dbabbage:

Anyway, it's clear what we've identified is an interaction between Safari and some particular aspect of the install on that site. On my local install I am running PHP v4.4.6, on the live server it is PHP v4.4.7.
I don't think it's a PHP version issue between 4.4.6 and 4.4.7.

I'm still inclined to think it's related to domain/cookie things though.

9 Sep 2007, 5:13 AM
#22
dbabbage avatar

dbabbage

New Zenner

Join Date:
Jul 2007
Posts:
30
Plugin Contributions:
0

Re: How to return to product page after login?

DrByte:

What exactly is the current symptom ?
Is it losing the login when clicking "login for price" links on product pages?
The current symptom is that the site works perfectly well, but the site continues to act as it did before the redirect code was installed—on login, the user is always returned to the front page of the site, if they were on a catalog category page, a product page, or an EZPages page at the time they clicked "log in". This symptom only occurs in Safari, and only on the live site (i.e. even in Safari, the redirect works correctly on my local development server install). In Firefox for Mac and Windows, and in IE 6 and 7 for Windows, users are now correctly redirected back to the category, product, or EZPages page on which they clicked the "Log In" link.

There is no problem with remaining logged in, with adding items to the cart, or with checking out. These all work fine in all browsers including Safari.

DrByte:

I don't think it's a PHP version issue between 4.4.6 and 4.4.7.

I'm still inclined to think it's related to domain/cookie things though.
OK. I'll see what I can do to check this from multiple Mac machines/users that have never before accessed the site...

9 Sep 2007, 7:57 AM
#23
dbabbage avatar

dbabbage

New Zenner

Join Date:
Jul 2007
Posts:
30
Plugin Contributions:
0

Re: How to return to product page after login?

DrByte:

I doubt it's related to that.
Nevertheless, those settings are in your configure.php files.
They are both set to store sessions in the db, so it is definitely not that, as you suspected.

Created a brand new Mac OS X user, which thus had no browser history, cookies, etc. Exactly the same symptoms in Safari, not correctly redirecting, whereas again worked just fine in Firefox. This is very odd.

9 Sep 2007, 1:22 PM
#24
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: How to return to product page after login?

I'm puzzled about why it only affects navigation things.

Try turning off the must-be-logged-in-for-prices switch again, so you're back to normal behaviour.
Log out of the store.
Then add something to your cart.
Then click Checkout.
It should ask you to login.
After login, does it take you back to checkout, or to home page ?

10 Sep 2007, 9:50 AM
#25
dbabbage avatar

dbabbage

New Zenner

Join Date:
Jul 2007
Posts:
30
Plugin Contributions:
0

Re: How to return to product page after login?

DrByte:

I'm puzzled about why it only affects navigation things.

Try turning off the must-be-logged-in-for-prices switch again, so you're back to normal behaviour.
...
After login, does it take you back to checkout, or to home page ?
OK. Followed all these steps. After login, it took me to the checkout, as it should. With the store set up with these settings (i.e. prices still visible) I also checked out whether the redirect was now working from the category and product pages—and the same problem was still there.

So, in the same browser, with the same store settings, it is correctly redirecting in the checkout process after login, but not from the other pages.

This is really bizarre.

10 Sep 2007, 9:55 AM
#26
dbabbage avatar

dbabbage

New Zenner

Join Date:
Jul 2007
Posts:
30
Plugin Contributions:
0

Re: How to return to product page after login?

dbabbage:

So, in the same browser, with the same store settings, it is correctly redirecting in the checkout process after login, but not from the other pages.
If this was doing this in all browsers, I would think that I had made some change to some Zen Cart code somewhere that was affecting this... But when it is specific to Safari, and only on this server?

I am thinking the some-work-but-best-next-step might be to install another entire Zen Cart installation on this hosting provider, and without modifying anything else put in the redirect code and see what it does. This would take out all the variables about any possible modifications I have made to the install (e.g. SEO URLs etc). Does this sound like a good idea?

My other thought is, perhaps there is something different in the .htaccess files on that server vs on my local installation. I'm running the same SEO URL rewriting on the local installation as on the server, but perhaps there is some difference in the .htaccess files that could be doing this? ETA: The .htaccess files, at least at the top level of the site, are identical. My guess is therefore I've copied them all over as part of the install and they are all identical. Also, if it was an issue with the .htaccess file I guess it wouldn't be browser-specific.