Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2009
    Posts
    75
    Plugin Contributions
    0

    Default Shopping Basket empties itself

    www.jaysmodelkits.com / ZC 1.5.7d / PHP 7.4.33

    I have received an email from a customer who states that whilst browsing the store the shopping basket kept emptying, it happened twice.
    Whilst browsing and selecting items to put in to the basket he spent time away from the computer to check something and came back to find the basket was empty. Total time period spent was 1 to 2 hours from the time he started browsing.
    Sounds to me like ZenCart has a time out feature which seems to empty the basket of items when a certain length of inactivity has been reached.
    Is this correct? and, if so, what is the time limit set to and can it be changed? Fortunately the customer was persistent and refilled his basket for a third time. But, I can see this could annoy some people leading to lost custom.
    Thanks in advance.

  2. #2
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,703
    Plugin Contributions
    123

    Default Re: Shopping Basket empties itself

    > Sounds to me like ZenCart has a time out feature which seems to empty the basket of items when a certain length of inactivity has been reached.

    The customer's session does time out after a while. You can modify the file define_shopping_cart.php in Admin > Tools > Define Pages editor to say something like:

    --
    Please sign in to see your stored shopping cart or create an account if you do not have one. Your items will be cleared from your cart after *** minutes of inactivity if you are not logged in.

    ---

    To get the value of *** go to the Version screen and look at session.gc_maxlifetime.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  3. #3
    Join Date
    Jan 2009
    Posts
    75
    Plugin Contributions
    0

    Default Re: Shopping Basket empties itself

    Thank you for that. Under session.gc_maxlifetime there are two values. I assume these are in seconds making the timeout limit as 15 minutes and 24 minutes. What is the difference between Local Value and Master Value? And can they be altered to a longer period, say 1 hour?

  4. #4
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,703
    Plugin Contributions
    123

    Default Re: Shopping Basket empties itself

    Some hosting environments allow you to change this and others don't. Try setting the define SESSION_TIMEOUT_CATALOG.

    Create the file includes/extra_configures/session_timeout.php

    <?php
    define('SESSION_TIMEOUT_CATALOG','3600');

    and see if that works.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  5. #5
    Join Date
    Jan 2009
    Posts
    75
    Plugin Contributions
    0

    Default Re: Shopping Basket empties itself

    Thanks for the suggestion I have created the new file and also discovered the files which includes the settings for the timeout period.
    I have altered those figures also to 3600 (1 hour). I tested it and it would seem the shopping basket now retains it's contents for what seems to be well over an hour.
    So, I would say the problem has been solved. Many thanks for your help.

 

 

Similar Threads

  1. v154 Guest Shopping Cart empties after 24 minutes
    By vickilapp in forum General Questions
    Replies: 3
    Last Post: 24 May 2017, 04:59 PM
  2. v138a Cart empties as customer is shopping
    By mahlerosa in forum General Questions
    Replies: 2
    Last Post: 19 Jan 2012, 10:59 AM
  3. Shopping cart empties and login times out
    By Ragenther in forum General Questions
    Replies: 9
    Last Post: 3 Apr 2011, 02:24 AM
  4. Replies: 2
    Last Post: 7 Oct 2009, 05:33 AM
  5. shopping cart empties itself--HELP
    By v0903856 in forum General Questions
    Replies: 10
    Last Post: 8 Sep 2007, 04:28 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR