New Zenner
- Join Date:
- Jun 2005
- Posts:
- 49
- Plugin Contributions:
- 0
move add to cart button
I want to move the add to cart button to below the picture instead of at the bottom.
Views: 3,202
New Zenner
I want to move the add to cart button to below the picture instead of at the bottom.
Black Belt
Start in the admin > config > one of the display or layout settings
New Zenner
Thank you that worked.
Zen Follower
hello,
i'd like to do the same ..move the add to cart button under the image on the product info page...with the description going down the left hand side
but i cant find any setting which will move it in admin>config
am I just being a blind dingbat or were you referring to the product listing page rather than info page? if so anoyone know what I need to do?
thanks
Totally Zenned
Yes, you will have to edit the tpl_product_display.php
Find it on includes/templates/template_default/templates
make a copy to your includes/templates/yourtemplate/templates
On that file you can move things around like you want them and you are using the override system to avoing braking the code. If something goes wrong, just delete and start over.
Have fun!
Zen Follower
kobra:
Start in the admin > config > one of the display or layout settings
Can you be more specific, I'm going nuts looking for it....... Again......
Thanks,
Obaa-san
In the tpl_product_info_display.php find this section:
<!--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="' . ($productGetInfo->getProductBuyNowQuantity()) . '" maxlength="6" size="4" /><br />' . $productGetInfo->getProductQuantityMinUnitsDisplay() . '<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-->
copy and paste that section where you want it.
Zen Follower
Its a conspericy!
I was looking for an easter egg that wasn't there. No wonder I couldn't find a place in admin to do this.
Thanks for the info on where to find the code. Now you truly think I would know what to do with it? I get it now. Its call job security! LOL
I wove you!!!
Works like a charm.
http://www.teamfasteddy.com/index.php?main_page=product_info&products_id=2
Obaa-san
LOLOL - Ed, I promise it really is easy. Each section of the page is clearly marked with:
<!--BOF some section-->stuff
<!--EOF some section-->Figure out which section you want the cart button above or below and move the section of code I showed you. :D
Zen Follower
I did it!
I did! I did! I did!!!, even posted a link above to show that im not lying.
Can i get bonus points towards being Zened, or a special name tag:
"I did it , So can you..."
Seriously,
Thanks!
Obaa-san
:thumbsup: :thumbsup:
Good job!!
<hands Ed a cookie>Tell staff why this post should be reviewed.