Results 1 to 10 of 10
  1. #1
    Join Date
    Mar 2008
    Posts
    56
    Plugin Contributions
    0

    Default Tried to move "Add to Cart" on Product Pages - Did Not Work!

    Okay,

    So I tied to change where my "add to cart" button is on product pages. I edited the following file:

    /includes/templates/CUSTOM/templates/tpl_document_product_info_display.php

    Nothing happened.

    As a side note I have all products set to display "out of stock", as I do not sell any products on the site You can see why by looking at my site www.kamaainadeals.com Even when I set the products to show "add to cart" button not "out of stock" button it is the same. Nothing has moved!

    Any ideas?



    Here's what my edited code looks like....


    Code:
    <!--bof Product URL -->
    <?php
      if (zen_not_null($products_url)) {
        if ($flag_show_product_info_url == 1) {
    ?>
        <p id="productInfoLink" class="docProduct centeredContent"><?php echo sprintf(TEXT_MORE_INFORMATION, zen_href_link(FILENAME_REDIRECT, 'action=url&goto=' . urlencode($products_url), 'NONSSL', true, false)); ?></p>
    <?php
        } // $flag_show_product_info_url
      }
    ?>
    <!--eof Product URL -->
    
    <!--bof also purchased products module-->
    <?php require($template->get_template_dir('tpl_modules_also_purchased_products.php', DIR_WS_TEMPLATE, $current_page_base,'templates'). '/' . 'tpl_modules_also_purchased_products.php');?>
    <!--eof also purchased products module-->
    <!--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 . '<input type="text" name="cart_quantity" value="' . (zen_get_buy_now_qty($_GET['products_id'])) . '" maxlength="6" size="4" /><br />' . zen_get_products_quantity_min_units_display((int)$_GET['products_id']) . '<br />' . 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-->
    
    <!--bof Form close-->
    </form>
    <!--bof Form close-->
    </div>

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

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    as I do not sell any products on the site
    Guess I don't understand why you need the add to cart then??
    Zen-Venom Get Bitten

  3. #3
    Join Date
    Mar 2008
    Posts
    56
    Plugin Contributions
    0

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    I don't! Is there some place I can get rid of it all together?

  4. #4
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,761
    Plugin Contributions
    9

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    I don't! Is there some place I can get rid of it all together?
    I did not see it??

    Maybe a link to a page where it is displayed,,,
    Zen-Venom Get Bitten

  5. #5
    Join Date
    Mar 2008
    Posts
    56
    Plugin Contributions
    0

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    Kobra,

    Thanks for your help you have helped me many times. You can see what I mean here

    You will notice that the out-of-stock image says "Lucky You Know". I didn't know what else to do but put a tagline for the site there. I would like for it to be gone all together...

  6. #6
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,761
    Plugin Contributions
    9

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    Try
    admin > config > my store > Store Status < set to either 1 or 2
    Zen-Venom Get Bitten

  7. #7
    Join Date
    Mar 2008
    Posts
    56
    Plugin Contributions
    0

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    Hi Kobra,

    Just tried that. It changed "more info" on the product listings page to "contact us" and also the "lucky you know" box changed to "contact us". I don't really want people to contact us (they need to contact the businesses listed on our site directly), sooo...

    I still am not liking the location of the box either way. Any ideas why it did not move below the "tell a friend" and "write a review" buttons?

    Was my code messed up somehow?


  8. #8
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,761
    Plugin Contributions
    9

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    Was my code messed up somehow?
    From what you posted I see the I can not determine exactly where you have relocated it to


    I have pasted the full block that you should be relocating or might try removing it

    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 . '<input type="text" name="cart_quantity" value="' . (zen_get_buy_now_qty($_GET['products_id'])) . '" maxlength="6" size="4" /><br />' . zen_get_products_quantity_min_units_display((int)$_GET['products_id']) . '<br />' . 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-->
    One can replace the call for price icon with a transparent image with the same name if that will be more to your liking
    Zen-Venom Get Bitten

  9. #9
    Join Date
    Mar 2008
    Posts
    56
    Plugin Contributions
    0

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    Finally got it! was editing tpl_documents_product_info_display instead of tpl_product_info_diplay.

    Silly me

  10. #10
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,761
    Plugin Contributions
    9

    Default Re: Tried to move "Add to Cart" on Product Pages - Did Not Work!

    Finally got it! was editing tpl_documents_product_info_display instead of tpl_product_info_diplay.
    I could not tell if you were using the document product type or not

    Glad you got it
    Zen-Venom Get Bitten

 

 

Similar Threads

  1. Replies: 0
    Last Post: 2 Jan 2011, 01:14 PM
  2. EasyPopulate problem: "Add to Cart" and "price" not showing on product info page
    By pcspot in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 29 Apr 2010, 08:06 AM
  3. Replies: 0
    Last Post: 17 Mar 2010, 05:24 PM
  4. Remove "Add: [ ]" and "Add selected products to cart" from product pages? possible?
    By edwardtilbury in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 1 Sep 2008, 03:13 AM
  5. Clicking "Add to Cart" on a review delivers "product not found"
    By bifficus in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 23 Nov 2007, 10:11 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