Results 1 to 2 of 2

Hybrid View

  1. #1
    Join Date
    Sep 2006
    Location
    North Devon, England, UK
    Posts
    289
    Plugin Contributions
    0

    Default Add to cart and attributes

    Hi

    On this page http://www.sorce.co.uk/logo-golf-bal...roducts_id=183, i have replaced the 'Add to Cart' button with my own.

    As you will see the actual button isn't aligned with the quantity box, but i don't know how/where to fix this.

    So far i have been messing with the code in this file, which is in tpl_product_info_display.php :

    Code:
    <!--bof Add to Cart Box -->
    <?php
    if (CUSTOMERS_APPROVAL == 3 and TEXT_LOGIN_FOR_PRICE_BUTTON_REPLACE_SHOWROOM == '') {
      // do nothing
    } else {
    ?>
                <?php
        $display_qty = (($flag_show_product_info_in_cart_qty == 1 and $_SESSION['cart']->in_cart($_GET['products_id'])) ? '<p>' . PRODUCTS_ORDER_QTY_TEXT_IN_CART . $_SESSION['cart']->get_quantity($_GET['products_id']) . '</p>' : '');
                if ($products_qty_box_status == 0 or $products_quantity_order_max== 1) {
                  // hide the quantity box and default to 1
                  $the_button = '<input type="hidden" name="cart_quantity" value="1" />' . zen_draw_hidden_field('products_id', (int)$_GET['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT);
                } else {
                  // show the quantity box
        $the_button = PRODUCTS_ORDER_QTY_TEXT . '<h3><img src="http://www.sorce.co.uk/logo-golf-balls/includes/templates/arch_shoppe/images/head-addtocart.gif" alt="Add to Cart" /></h3>' . '<input type="text" name="cart_quantity" value="' . (zen_get_buy_now_qty($_GET['products_id'])) . '" maxlength="6" size="4" />' . zen_get_products_quantity_min_units_display((int)$_GET['products_id']) . '' . zen_draw_hidden_field('products_id', (int)$_GET['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT);
                }
        $display_button = zen_get_buy_now_button($_GET['products_id'], $the_button);
      ?>
      <?php if ($display_qty != '' or $display_button != '') { ?>
        <div id="cartAdd">
        <?php
          echo $display_qty;
          echo $display_button;
                ?>
              </div>
      <?php } // display qty and button ?>
    <?php } // CUSTOMERS_APPROVAL == 3 ?>
    <!--eof Add to Cart Box-->
    I do get the feeling that there might be a more specific file to change, can anyone let me know which one this might be?

    You will see that i hard coded the Add to Basket image text on this page, which i'm not sure is the best way.

    Another thing, on the same page, where the Attribute is for Image Upload I would like to change the upload button to an image, like the Add to cart button. Can anyone advise how i might do this and which file(s) to change?
    Last edited by mattys; 27 Oct 2006 at 12:44 PM.

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,755
    Plugin Contributions
    9

    Default Re: Add to cart and attributes

    Looking at your entry I think that this is for the image over the "add" button and I think that you are referring to the "add" button alignment??
    Zen-Venom Get Bitten

 

 

Similar Threads

  1. move? add to cart and attributes
    By bobin in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 4 Apr 2010, 02:28 AM
  2. Move Add to Cart and Attributes
    By sgallant in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 7 Dec 2008, 11:21 PM
  3. Changed Order of Add to Cart Box and Attributes and now having a weird problem
    By sgallant in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 4 Dec 2008, 07:26 PM
  4. aligning attributes and add to cart
    By MachaNeko in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 27 May 2008, 06:44 PM
  5. add to cart and attributes
    By kitcorsa in forum General Questions
    Replies: 5
    Last Post: 3 May 2007, 11:33 AM

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