Results 1 to 10 of 48

Hybrid View

  1. #1
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Limit Quantities for Downloads and Virtual Products [Support Thread]

    I had the easy part ... breaking stuff ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  2. #2
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    10,021
    Plugin Contributions
    32

    Default Re: Limit Quantities for Downloads and Virtual Products [Support Thread]

    Quote Originally Posted by Ajeh View Post
    I had the easy part ... breaking stuff ...
    That is the fun part!!
    My Site - Zen Cart & WordPress integration specialist
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  3. #3
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Limit Quantities for Downloads and Virtual Products [Support Thread]

    Yes ... it is ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  4. #4
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Limit Quantities for Downloads and Virtual Products [Support Thread]

    Houston ... we have a problem ...

    If a Product is a Gift Certificate and Priced by Attributes it is being treated like a download due to the setting:
    Code:
      if (zen_get_products_virtual($products_id)) return true;
    Virtual Products are not Downloads ... Downloads are only Downloads if there is a filename on the Attribute ...

    Is there another case where a Download would be a Virtual Product that I am forgetting?
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  5. #5
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    13,874
    Plugin Contributions
    96

    Default Re: Limit Quantities for Downloads and Virtual Products [Support Thread]

    Ajeh, thanks for the continued testing! The correction for that boo-boo is simple, just comment out the virtual-product check in the ldProductIsDownload function of /includes/extra_cart_actions/limit_downloads.php:
    Code:
    function ldProductIsDownload ($products_id, $options_id, $options_value_id) {
      global $db;
    //-v1.1.2d  if (zen_get_products_virtual($products_id)) return true;
      
      $sql = "SELECT count(*) as count
              FROM " . TABLE_PRODUCTS_ATTRIBUTES_DOWNLOAD . " pad, " . TABLE_PRODUCTS_ATTRIBUTES . " pa
              WHERE pa.products_id = " . (int)$products_id . "
              AND   pa.options_id = " . (int)$options_id . "
              AND   pa.options_values_id = " . (int)$options_value_id . "
              AND   pa.products_attributes_id = pad.products_attributes_id";
      $sql_result = $db->Execute($sql);
    
      return ($sql_result->fields['count'] > 0) ? true : false;
    }
    I'll get this packaged up (again ...)

  6. #6
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Limit Quantities for Downloads and Virtual Products [Support Thread]

    That was pretty much my conclusions as well ... and appeared to work on a couple tests last night ...

    I cannot think of anything that would be a Download and marked as a Virtual Product or any Virtual Product where you would want to alter the quantities ...

    Thanks for staying on top of things ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  7. #7
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    13,874
    Plugin Contributions
    96

    Default Re: Limit Quantities for Downloads and Virtual Products [Support Thread]

    This plugin is also safe to use on Zen Carts v1.5.2 and v1.5.3.

  8. #8
    Join Date
    Jul 2012
    Posts
    16,816
    Plugin Contributions
    17

    Default Re: Limit Quantities for Downloads and Virtual Products [Support Thread]

    Quote Originally Posted by Ajeh View Post
    That was pretty much my conclusions as well ... and appeared to work on a couple tests last night ...

    I cannot think of anything that would be a Download and marked as a Virtual Product or any Virtual Product where you would want to alter the quantities ...

    Thanks for staying on top of things ...
    I've recently (ZC 1.5.3) run across the need to mark a downloadable product that includes an attribute as virtual in order to bypass the request for a shipping address while processing the payment.

    Downloadables not marked as virtual that result in asking for shipping created to demonstrate this issue:
    http://mc12345678.webatu.com/index.p...&products_id=8
    http://mc12345678.webatu.com/index.p...&products_id=9

    Same downloadables marked as virtual that do not display shipping options during checkout:
    http://mc12345678.webatu.com/index.p...&products_id=3
    http://mc12345678.webatu.com/index.p...&products_id=1

    The limit quantities for download modification described here has not been applied (yet), but did see that the above question was not answered in this thread..
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

 

 

Similar Threads

  1. v154 All Products Virtual -- No Shipping [Support Thread]
    By lat9 in forum All Other Contributions/Addons
    Replies: 16
    Last Post: 22 Jul 2019, 12:04 PM
  2. v153 Restrict Digital Downloads [Support Thread]
    By lat9 in forum All Other Contributions/Addons
    Replies: 112
    Last Post: 19 Jan 2016, 05:46 PM
  3. v154 Email Downloads Support Thread
    By swguy in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 17 Jun 2015, 06:41 PM
  4. v151 Virtual Agent ASKOM Support Thread
    By askom in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 3 Apr 2014, 09:13 AM
  5. difference between downloads and virtual products
    By artcoder in forum General Questions
    Replies: 2
    Last Post: 20 Feb 2008, 11:42 PM

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