for vr4indian,
to show a button instead of "more info":
in english.php ...
Code:
define('MORE_INFO_TEXT','<img src="/link/to/your/button.gif">');
...
for my problem -- found the answer by combining ideas from a couple of older threads...
1. to switch the "buy now" button and activity to a "more info" button and activity:
in /includes/modules/product_listing.php, find:
Code:
// qty box with add to cart button
if (PRODUCT_LIST_PRICE_BUY_NOW == '2' && $listing->fields['products_qty_box_status'] != 0) {
$lc_button= zen_draw_form('cart_quantity', zen_href_link(zen_get_info_page($_GET['products_id']), zen_get_all_get_params(array('action')) . 'action=add_product&products_id=' . $listing->fields['products_id']), 'post', 'enctype="multipart/form-data"') . '<input type="text" name="cart_quantity" value="' . (zen_get_buy_now_qty($listing->fields['products_id'])) . '" maxlength="6" size="4" /><br />' . zen_draw_hidden_field('products_id', $listing->fields['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT) . '</form>';
} else {
replace the line just below that with:
Code:
$lc_button = '<a href="' . zen_href_link($_GET['main_page'], zen_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing->fields['products_id']) . '">' . zen_image_button(BUTTON_IMAGE_BUY_NOW, BUTTON_BUY_NOW_ALT, 'class="listingBuyNowButton"') . '</a>';
2. to hide "max:1"...
you can always remove max:1 by setting the maximum field in the admin->categories-->product listing to '0' ("Qty Max":0 , meaning "unlimited"). that hides the max:1 but then the product behaves as if there are potentially many of them.
i wanted the product to behave like a one-of-a-kind, since the shop sells original drawings. if you set Qty Max:0 (unlimited), you can still set the "products quantity" field to 1. in that case, customers can add more than one of the product to their cart by going back to the product page and clicking "add to cart" again and again. if they do that, they'll get a RED error message saying that there are insufficient quantities in stock so please reduce the number in the cart. but if you've turned off the "number of products" field in the shopping cart, there's no way to do that except by deleting the product from the cart and starting again, just adding it once.
on the other hand, if "Qty Max:1", customers who try to add additional copies of the same (one-of-a-kind) item to the cart get a YELLOW error message saying that the quantity has been (automatically) altered, since they can't add more than the MAX to their cart. in other words, Qty Max:1 prevents customers from adding more than one of that item to the cart. and the customer doesn't have to do anything to correct the situation.
so that's good, but then you have "Max:1" showing up on your categories page, shopping cart, etc -- right?
not necessarily.
in /includes/functions/functions_price.php , find:
Code:
if ($check_max != 0 {
and replace that line with
Code:
if ($check_max != 0 && $check_max != 1) {
NOTE that you can't save a functions/ file to functions/your_template/whatever.php and expect it to override -- it won't.
so i've saved the original file as functions_price.bak (as backup), and the new file (with the change above) is the new functions_price.php
and just like that, Max:1 is gone.
Bookmarks