Results 1 to 6 of 6
  1. #1
    Join Date
    Jan 2013
    Posts
    811
    Plugin Contributions
    0

    Default Exclude certain items from the TEXT_PRODUCT_FREE_SHIPPING_ICON

    i installed this file https://www.zen-cart.com/attachment....8&d=1243290689 how can i query the flag i set in tpl_product_info_display

  2. #2
    Join Date
    Jan 2013
    Posts
    811
    Plugin Contributions
    0

    Default Re: Exclude certain items from the TEXT_PRODUCT_FREE_SHIPPING_ICON

    i need to find this if($_SESSION['cart']->flag_exclude_free_shipping){ when not in cart($_session) to change a flag to false on a majority of items

  3. #3
    Join Date
    Jul 2012
    Posts
    16,734
    Plugin Contributions
    17

    Default Re: Exclude certain items from the TEXT_PRODUCT_FREE_SHIPPING_ICON

    A visual inspection of the referenced code looking at a modification of the admin/includes/modules/product/collect_info.php file, there appears to be a database field added to the products table called: products_carrot.

    Based on that, an assumption (without fully installing the plugin) is that you are wanting to have access to the data stored there and then to take action similar to what is performed while looking at the product page.

    Data made available on the product page is typically collected through files in includes/modules/pages/product_info.

    To pull the products_carrot field, it would need to be a part of the query of the associated product or through a separate query specifically to return that field's value from the products table.

    Typically this is done either in one of the main_template_vars_* files or as a result of their execution (observer). Even though you are using ZC 1.5.1 (as reported when posting), it is still possible to use the observer class to get and set the necessary data.

    After retrieving the field, it seems like you would want to "process" it to get the same result as obtained through the shipping class. It may not be by modifying the cart session, but the same effect can be obtained.

    Whatever is done, just remember that you may want to consider the ability to apply the modification to other product types and also how you will apply it through the upgrade path. (good documentation helps with that.)
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  4. #4
    Join Date
    Jan 2013
    Posts
    811
    Plugin Contributions
    0

    Default Re: Exclude certain items from the TEXT_PRODUCT_FREE_SHIPPING_ICON

    i have over 6500 products to set this flag on, it is not in Products DbName:  Screenshot_2018-10-29 jnsflooringandsupplies com localhost c1JNSFlooring products phpMyAdmin 4 0.jpg
Views: 64
Size:  61.9 KB
    Last edited by jimmie; 29 Oct 2018 at 05:34 PM.

  5. #5
    Join Date
    Jan 2013
    Posts
    811
    Plugin Contributions
    0

    Default Re: Exclude certain items from the TEXT_PRODUCT_FREE_SHIPPING_ICON

    Just trying to get this to work
    Code:
    			                        <!--bof free ship icon  -->
                            <?php if ($product_is_always_free_shipping >= 3) { ?>
                                <div id="freeShippingIcon"><?php echo TEXT_PRODUCT_FREE_SHIPPING_ICON; ?></div>
                            <?php } ?>
                            <!--eof free ship icon  -->

  6. #6
    Join Date
    Jan 2013
    Posts
    811
    Plugin Contributions
    0

    Default Re: Exclude certain items from the TEXT_PRODUCT_FREE_SHIPPING_ICON

    figured it out had to do it like this
    Code:
    <?php if($product->fields['product_is_always_free_shipping'] == 0) { ?>

 

 

Similar Threads

  1. Exclude items from the Group Pricing Discount
    By MerseyRay in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 16
    Last Post: 17 Nov 2022, 10:56 AM
  2. Replies: 0
    Last Post: 14 Aug 2010, 12:35 PM
  3. Flat Rate / Over $250.00 FREE shipping exclude certain items
    By WebSiteGuru in forum Built-in Shipping and Payment Modules
    Replies: 5
    Last Post: 31 Dec 2008, 04:44 AM
  4. Exclude certain categories from spiders
    By Blake81 in forum General Questions
    Replies: 0
    Last Post: 10 Dec 2007, 12:31 PM
  5. Exclude certain products from Paypal option
    By AndyBB in forum Built-in Shipping and Payment Modules
    Replies: 3
    Last Post: 30 Aug 2007, 08:09 PM

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