Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Out of Stock Buttons


Recommended Posts

This is an ok contrib but I can not get rid of the OUT OF STOCK buttons in the product_listing.php page of the site. They are allways shown no matter what stock level is set or not.

 

This is a serious problem. Can someone confirm this works or find a solution?

 

For now I took out the buy it now colum through the admin.

 

It does work great in the products description pages however.

 

Help

Link to comment
Share on other sites

This was a fix that was sent to me by JuxiZoza for the problem

 

 

 

First, since the buttons display and I assume work properly for individual listings... the problem is elsewhere.

 

I believe the problem you have is because you elected to NOT display the quantities available.

 

See... "Administration / Product Listing / Display Product Quantity" and turn on display of quantities by using a number other than 0. I have tested this and was able to create the problem you cited.

 

The display switch apparently needs to be on. That was not apparent to me when I made the contribution, because I had it turned on and did not appreciate its impact on the contribution.

 

If that corrects the button problem AND you still don't want the quantities to show... then try Eric's mod to the contribution to turn display of quantities back off.

 

 

Here is Erics mod

 

// Mod by Eric Haskins http://www.rackspeed.net [email protected]

// To Allow this mod to work without displaying Quantity in listing

 

\catalog\includes\modules\product_listing.php

line 46

 

case 'PRODUCT_LIST_QUANTITY':

$lc_text = TABLE_HEADING_QUANTITY;

$lc_align = 'right';

break;

--------------------------------

replace with:

// Mod for Not Showing Quantity with No Stock No CheckOut

//$lc_text = TABLE_HEADING_QUANTITY;

$lc_text = '';

$lc_align = 'right';

break;

--------------------------------

 

line 115

 

case 'PRODUCT_LIST_QUANTITY':

$lc_align = 'right';

$lc_text = ' ' . $listing['products_quantity'] . ' ';

break;

--------------------------------

replace with:

case 'PRODUCT_LIST_QUANTITY':

$lc_align = 'right';

// Mod for Not Showing Quantity with No Stock No CheckOut

// $lc_text = ' ' . $listing['products_quantity'] . ' ';

$lc_text = '  ';

break;

==========================================================

// End Eric Haskins Mod

 

 

Hope it worked it did for me

 

www.airsoftmart.net

Link to comment
Share on other sites

  • 2 years later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...