If this is your first visit, check our documentation. To post, register or login.
Forums / Other Business Topics / Customer cannot logout (ie, uses logout but still logged in next visit)

Customer cannot logout (ie, uses logout but still logged in next visit)

Started by lindagal2 on 1 Aug 2017, 1:39 AM · Views: 157

Results 1 to 11 of 11
1 Aug 2017, 1:39 AM
#1
lindagal2 avatar

lindagal2

New Zenner

Join Date:
Jan 2008
Posts:
73
Plugin Contributions:
0

Customer cannot logout (ie, uses logout but still logged in next visit)

For some reason customers cannot log out from our store. They click the logout and think they are logged out but when they next visit, they are still logged in. What can I do?

Also, we want customer to be able to create account if they'd like, but also be able to check out as a guest. Currently, ZC is creating an account automatically. So 1) how do I shut off automatic account creation, and 2) is there an option for guest checkout anywhere?

Thx.

1 Aug 2017, 3:30 AM
#2
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

lindagal2:

For some reason customers cannot log out from our store. They click the logout and think they are logged out but when they next visit, they are still logged in. What can I do?

Also, we want customer to be able to create account if they'd like, but also be able to check out as a guest. Currently, ZC is creating an account automatically. So 1) how do I shut off automatic account creation, and 2) is there an option for guest checkout anywhere?

Thx.

Some of this can be answered easier by addressing the posting tips.

Can make assumptions (ie. what feature/process is generating the automatic account creation?).

Guest checkout related options are currently available by plugin(s). There's COWOA (Check-Out With-Out an Account) (seems like there are at least 2 versions one specifically dedicated to this feature one as an add-on), COWOAA (Check-Out With-Out Any Account), and a few others that escape me at the moment.

The first behavior described is not normal for a standard/vanilla ZC installation. Something is different about the configuration/setup than expected and perhaps this has driven to the two questions, perhaps the questions are unrelated to the original issue. Again, addressing the posting tips would help work through this.

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

1 Aug 2017, 7:45 AM
#3
lindagal2 avatar

lindagal2

New Zenner

Join Date:
Jan 2008
Posts:
73
Plugin Contributions:
0

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

Good points and my apologies for improper posting ...
ZenCart version 1.5.5, and php v 5.6.31

Plugins: are 1) Paypal express checkout; 2) FedEx shipping; and 3) Group Pricing (per item) which includes SQL patch (although the login prob was happening before I installed this last plugin).

It sounds like the COWOA (Check-Out without an account) would help with half of my problem (although not sure which one of the two versions to use so any suggestions would be appreciated). However, still don't know what causes the continued log-in. There is a thread mentioning this problem but it is from 2007 and involves a modified footer (the only thing I've done with our footer so far is remove the banner ad) so I'm reluctant to change code I don't understand if it may or may not still be relevant 10 years later. But here's the link: https://www.zen-cart.com/showthread.php?79156-Log-In-Log-Out

Thx.

1 Aug 2017, 1:17 PM
#4
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

What about the origin of the install? Ie. Package/auto install or download from this site? History of the store as in upgraded, original install, etc... How was recent install performed? (ie. When upgrading from X, copied new files over the old did/did not remove files that were not a part of the current version; installed all the files into a directory, added plugins, moved old files out of the way, moved/copied new files in and modified configure.php files as applicable; someone else did it and I don't know what/how things were done; etc...)

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

1 Aug 2017, 9:06 PM
#5
lindagal2 avatar

lindagal2

New Zenner

Join Date:
Jan 2008
Posts:
73
Plugin Contributions:
0

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

mc12345678:

What about the origin of the install? Ie. Package/auto install or download from this site? History of the store as in upgraded, original install, etc... How was recent install performed? (ie. When upgrading from X, copied new files over the old did/did not remove files that were not a part of the current version; installed all the files into a directory, added plugins, moved old files out of the way, moved/copied new files in and modified configure.php files as applicable; someone else did it and I don't know what/how things were done; etc...)

This site is a new install, downloaded from ZenCart site. Install was about 3 weeks ago and store is still not up and running as we are learning to install needed plugins and then customize it. We installed two plugins (the above referenced Paypal express checkout and FedEx shipping modules) and then did our first merchandise test. The login problem (ie, keeping test customer logged in despite having clicked logout) occurred then, so it is not a problem with the third plugin (Group Pricing (per item)). There are some other setting changes (ie through the admin panel, NOT plugins). Do you need to know those as well?

History: This store was originally installed with version 1.2.x and we tried for nearly a month to get the upgrade to work but were never successful, in part because it had never been updated through many years, and we continued to have problems with upgrading (it would upgrade some older versions but could not upgrade earlier versions, even when we tried to install earlier version. Ultimately we decided on a clean install and re-adding all new merchandise by hand (new database). So there would not be any problems from prior version since everything in this site is new (except an already established paypal account, which info we entered when we installed the PayPal Express checkout plugin). This is the first store I have ever installed.

Re the plugins, I did not copy old files and "move old files out of the way" although I did backup the database. (Since it was a brand new install, I figured if there was a problem I could simply reinstall at that point and import the db.) If I had it to do over again, should I have created a template first and THEN done the plugins so I always had those old files? (I originally thought templates were for the appearance part ie, color, banners, etc but as I go further into the process think that was an error. When does one usually create the template during the process??)

Here is the FedEx plugin used in addition to PayPal Express Checkout module:
https://www.zen-cart.com/downloads.php?do=file&id=1784

Here is the Group Pricing (per item) plugin (but as noted, problem occurred before this install so don't think it is relevant):
https://www.zen-cart.com/downloads.php?do=file&id=154

So at this point, since it sounds like the COWOA plugin (Check-Out without an account) you suggested would solve the problem of howto pay without an account, my questions are: 1) How do I stop ZenCart from creating an account automatically yet still let the customer create one if s/he wishes (ie, is there a setting I'm missing? ZC is automatically making an account at this point and sending letter after the fact); and 2) how do we solve the login problem (although that is an annoyance rather at this point and I've really got to get the store up and open).

Thanks.

2 Aug 2017, 1:29 AM
#6
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

The auto account creation is a "feature" of paypal.

Ahh, yes, forgot about the issues with upgrading that early version of ZC was related. Shame to think that if effort had continued to resolve that issue that it would have been done by now and that perhaps related issues could have been addressed for others that may be/been in the same position. :P

As to template or not to template, overall it is just easiest to start with a template then add to it. It can be done either way, but as you have or may find is that if a template touches the same files that you have otherwise modified (even in a different template), then those same changes need to be made to the new template. And depending on the plugin this can be easy or present its own issues (install does many things automatically including placing files in the active template as well as trying to do sql modifications that have already been done, etc...) but... please hold back the alarm, each plugin is different and the ease of reinstalling/merging is different as well. The important thing to consider about these two parts is that each should be based off of a vanilla zencart install so finding the place(s) to edit ought to be relatively easy.

The other thing about starting with a separate template (even if a copy of one of the existing installed versions) is that by having a separate template folder you can switch back to one of the "default" templates and see if things operate like they should when they don't in the current/new one. Also, upgrades tend to be made easier because your modifications shouldn't be touched by the upgrade when the changes have been made in a template override. The thing there is to identify what changed in the base version and see if the same change(s) should be incorporated into your new template.

The other setting changes may be important to the original issue if they are made say to the sessions or to the pci related settings. The issue, while seeming annoying, can actually be a security issue. What's say someone is in the library (yeah, I know) and has navigated the site, made a purchase, "logged out", and then someone comes behind them and goes to the same site? What then? What information do they now have?

To be sure also, the zenid of any pages hasn't been explicitly sent out from the store has it? That would be a page like: ```
mydomain.com/index.php?main_page=product_info&cPath=1&products_id=1&[b]zenid=[/b]

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

2 Aug 2017, 5:44 AM
#7
website_rob avatar

website_rob

Inactive

Join Date:
Oct 2006
Location:
Alberta, Canada
Posts:
4,572
Plugin Contributions:
0

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

lindagal2:

For some reason customers cannot log out from our store. They click the logout and think they are logged out but when they next visit, they are still logged in. What can I do?

Admin -> Configuration -> Sessions
Cookie Domain
Force Cookie Use

  • make sure they both say True

The learning is in the doing.

Potent Products

2 Aug 2017, 9:43 AM
#8
lindagal2 avatar

lindagal2

New Zenner

Join Date:
Jan 2008
Posts:
73
Plugin Contributions:
0

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

mc12345678:

The auto account creation is a "feature" of paypal.

After reading your remark :blush: I double-checked my settings in PayPal Express Checkout plugin and click NO under "Express Checkout: Automatic Account Creation" (D'oh. This is why we re-check things we're "positive" we already set to "no.") So thank you for that!

mc12345678:

Ahh, yes, forgot about the issues with upgrading that early version of ZC was related. Shame to think that if effort had continued to resolve that issue that it would have been done by now and that perhaps related issues could have been addressed for others that may be/been in the same position. :P

If only I could forget those days as well. :P

The other thing about starting with a separate template (even if a copy of one of the existing installed versions) is that by having a separate template folder you can switch back to one of the "default" templates and see if things operate like they should when they don't in the current/new one. Also, upgrades tend to be made easier because your modifications shouldn't be touched by the upgrade when the changes have been made in a template override. The thing there is to identify what changed in the base version and see if the same change(s) should be incorporated into your new template.

The other setting changes may be important to the original issue if they are made say to the sessions or to the pci related settings. The issue, while seeming annoying, can actually be a security issue. What's say someone is in the library (yeah, I know) and has navigated the site, made a purchase, "logged out", and then someone comes behind them and goes to the same site? What then? What information do they now have?

To be sure also, the zenid of any pages hasn't been explicitly sent out from the store has it? That would be a page like: ```
mydomain.com/index.php?main_page=product_info&cPath=1&products_id=1&[b]zenid=[/b]


Yes.  Good point.  So  really have to figure this out.  You mention ZenID pages ... not that I *know* of but is there a way for me to check that?   Just because I'm not seeing something does't mean it's not there (as we just discovered with the PayPal Express Checkout Automatic Account setting!)   So how would I check if that is created?  Otherwise, what is my next step?   

Incidentally, just tested again with my personal paypal account and if I hit the "cancel and return to store" link at the bottom of the page (after logging into paypal but before reaching the shipping confirmation button) then ZenCart (or paypal) doesn't add all my information into the ZenCart "customers" section, and keeps me logged out of paypal next time I try to shop.   However, if I get to the shipping window, and click continue, there is no longer a way for me to cancel the transaction (the cancel and return to store link no longer shows on the page anywhere) and then when I return back to the store, even if I click "logout" at the top, I am still logged into paypal the next time I add anything to the basket.  Is there a setting somewhere I'm missing?   How can I make it easier for customers to cancel a transaction and make sure they are logged out of paypal?  


Incidentally, I still need to do the COWOA plugin but think I should wait until we fix the login issue.  Last but not least, I have about 20 small questions that I've googled and either not found an adequate answer, or want to double check that an old answer is still valid with 1.5.5e.   Should I do each question separate in the ZenCart forum or should I just list them and pray for mercy?  

Thx!
2 Aug 2017, 4:52 PM
#9
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

lindagal2:

Incidentally, just tested again with my personal paypal account and if I hit the "cancel and return to store" link at the bottom of the page (after logging into paypal but before reaching the shipping confirmation button) then ZenCart (or paypal) doesn't add all my information into the ZenCart "customers" section, and keeps me logged out of paypal next time I try to shop. However, if I get to the shipping window, and click continue, there is no longer a way for me to cancel the transaction (the cancel and return to store link no longer shows on the page anywhere) and then when I return back to the store, even if I click "logout" at the top, I am still logged into paypal the next time I add anything to the basket. Is there a setting somewhere I'm missing? How can I make it easier for customers to cancel a transaction and make sure they are logged out of paypal?
That is entirely on PayPal's end. Zen Cart has no control over that. It's not a Zen Cart issue.

What's happening is when you logged in to PayPal you set a PayPal cookie on your computer, which lets you transact with PayPal more quickly in future purchases. It will expire after a short time, according to whatever rules PayPal has predetermined. If you don't want that cookie set, sometimes Paypal gives you a checkbox to offer you the option of not setting that cookie (ie: "are you on a private computer?"). But none of that has anything to do with Zen Cart. And Zen Cart can't force that behavior on or off. Or you can just always use private-browsing mode in your browser.

On private computers (by far the marjority) this is pretty much a non-issue.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

3 Aug 2017, 3:09 PM
#10
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

DrByte, you mention that it is likely a result of a PayPal cookie. Does that mean that even if ZC dropped the session data associated with the recent attempt that the same would hold true? I ask, because it didn't seem like there was anything done to remove that session data until the paypal incontext option was expanded in ZC 1.6.0. I haven't been able to test this yet because I haven't put my store's paypal in test mode to be able to use an alternate set of paypal credentials.

As to the 20 questions: if the questions are sufficiently posed something similar to the above statement that have searched for many and wanted to ask these, and then each question is separate from the rest. If a moderator sees it as necessary, they will edit the post(s) to benefit others. Otherwise, have no fear... :). Worst that happens is someone posts angry words. :P

ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...

3 Aug 2017, 3:15 PM
#11
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Re: Customer cannot logout (ie, uses logout but still logged in next visit)

mc12345678:

DrByte, you mention that it is likely a result of a PayPal cookie. Does that mean that even if ZC dropped the session data associated with the recent attempt that the same would hold true?
I expect so, yes, because it's not related to Zen Cart sessions. Zen Cart has no control over whether PayPal remembers that a customer is logged in to PayPal (that's up to Paypal, the customer, and their browser).

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.