Thanks for the response Kobra.
I have worked out how to change the image. The problem now is that I can't work out a way to still let them order the "special order" items (i.e. add to cart). Any ideas would be greatly appreciated.
Printable View
Yes when I started the thread I'd already found the advice here on the forum on how to change the sold out image to whatever is preferred.
The only thing we need to figure out now is how to stop the "add to cart" button disappearing.
Surely, this is an easy task? Please please Zencart master's help us!!!
Ok. Here's the code for the "add to cart" box:
This is from:Quote:
<!--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-->
/home/[ADMIN FOLDER]/public_html/includes/templates/template_default/templates/tpl_product_info_display.php
I'm fairly certain altering one of these "if" functions would fix the problem but haven't worked it out yet. Any help would be very much appreciated.
=)
Hey, well done finding that!!!
With altering an IF function, could this code be tacked on underneath the code for the "sold out" button, which already displays at stock = 0 . . . . . or perhaps it would need some kind of AND statement before the 'Add to Cart' code and before the 'Sold Out' code.
I'm pretty sure the change would not need to be made within this text, but that's about as far as I've gotten... oh dear...
I'm willing to negotiate to pay someone to help me get this fixed. Please email me at tojasonharris (at) yahoo.com if you are willing to do this.
All I want to do is add a data base query that checks and returns an image if less than 1 is in stock. If it were Excel it would look like this:
=IF(QTY_IN_STOCK<1, [return out of stock image], " ")
We did get a fix for this. It should show up on the free downloads area eventually. If anyone has a link for it, please post it here.