Results 1 to 4 of 4
  1. #1
    Join Date
    Apr 2008
    Location
    Montreal, Quebec, Canada
    Posts
    28
    Plugin Contributions
    0

    Default How to remove the Update Cart button completely?

    Is there a way to remove the Update Cart (or Refresh Cart) button completely? ?

    I know that in
    admin/configuration/stock/

    You have the setting:
    Show Shopping Cart - Update Cart Button Location

    And then you have 3 choices, by radio buttons
    1= Next to each Qty Box
    2= Below all Products
    3= Both Next to each Qty Box and Below all Products


    With any of these choices, the Update Cart will apear somewhere, I cannot remove it from there.

    All my products can only be ordered in quantities of 1, so there is never a need to "refresh" the cart in my case

    Thanks in advance

  2. #2
    Join Date
    Apr 2008
    Location
    Montreal, Quebec, Canada
    Posts
    28
    Plugin Contributions
    0

    Default Re: How to remove the Update Cart button completely?

    I do know that this button is called
    'button_update_cart.gif' and that it is defined by the variable 'ICON_IMAGE_UPDATE'

    and that this variable is mentionned in two files:


    /includes/modules/pages/shopping_cart/header_php.php

    Line #139 : $buttonUpdate = ((SHOW_SHOPPING_CART_UPDATE == 1 or SHOW_SHOPPING_CART_UPDATE == 3) ? zen_image_submit(ICON_IMAGE_UPDATE, ICON_UPDATE_ALT) : '') . zen_draw_hidden_field('products_id[]', $products[$i]['id']);



    /includes/templates/template_default/templates/tpl_shopping_cart_default.php

    Line #137 : <div class="buttonRow back"><?php echo zen_image_submit(ICON_IMAGE_UPDATE, ICON_UPDATE_ALT); ?></div>


    But I don't know what to do with this information!

  3. #3
    Join Date
    Feb 2005
    Location
    Lansing, Michigan USA
    Posts
    18,039
    Plugin Contributions
    1

    Default Re: How to remove the Update Cart button completely?

    You'd want to remove or comment out the line 137 in includes/templates/template_default/templates/tpl_shopping_cart_default.php , then store the edited file in the proper override folder.

  4. #4
    Join Date
    Apr 2008
    Location
    Montreal, Quebec, Canada
    Posts
    28
    Plugin Contributions
    0

    Default Re: How to remove the Update Cart button completely?

    For some reason (maybe because I have a custom template?) nothing happened when I remove the line in the file tpl_shopping_cart_default.php

    What DID worked for me was to simply take this file:

    /includes/modules/pages/shopping_cart/header_php.php


    Line #139 : $buttonUpdate = ((SHOW_SHOPPING_CART_UPDATE == 1 or SHOW_SHOPPING_CART_UPDATE == 3) ? zen_image_submit(ICON_IMAGE_UPDATE, ICON_UPDATE_ALT) : '') . zen_draw_hidden_field('products_id[]', $products[$i]['id']);

    and change the 1 for a 0

    Line #139 : $buttonUpdate = ((SHOW_SHOPPING_CART_UPDATE == 1 or SHOW_SHOPPING_CART_UPDATE == 3) ? zen_image_submit(ICON_IMAGE_UPDATE, ICON_UPDATE_ALT) : '') . zen_draw_hidden_field('products_id[]', $products[$i]['id']);

    since the positioning parameter is set at 1 in admin/config/stock ... when the code read that line, there's no 1, so I get no button

    I dont know if this has over implications that I haven thought of yet but everything seems to be working great :)

 

 

Similar Threads

  1. Remove Update Button From Shopping Cart when priced by attributes?
    By khaber in forum Customization from the Admin
    Replies: 7
    Last Post: 30 Jul 2008, 02:55 PM
  2. How to remove 'Go to Checkout' button completely.
    By jordangottlieb in forum Addon Payment Modules
    Replies: 5
    Last Post: 5 Feb 2008, 11:15 PM
  3. HELP: HOW to Remove "Add to cart" button (function) completely!??:((
    By chelsea1984 in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 14 Aug 2007, 06:44 AM
  4. Remove update button from cart box
    By longstockings in forum Templates, Stylesheets, Page Layout
    Replies: 8
    Last Post: 3 Jun 2007, 03:05 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
  •