robkwal Posted June 17, 2011 Share Posted June 17, 2011 I would like to know how to remove both availability text within product list and the actual product! As all the products i sell are in stock, so it is unnecessary!Regards,Rob Link to comment Share on other sites More sharing options...
robkwal Posted June 17, 2011 Author Share Posted June 17, 2011 Can anyone help with this?! Link to comment Share on other sites More sharing options...
Sam Bahrn Posted June 19, 2011 Share Posted June 19, 2011 Hi Rob,To remove 'available' on product list page :1. open .../themes/your theme/product-list.tpl2. search for the following codes (in v 1.4.3 default theme its on line 44) : {if isset($product.available_for_order) && $product.available_for_order && !isset($restricted_country_mode)}{if ($product.allow_oosp || $product.quantity > 0)}{l s='Available'}{elseif (isset($product.quantity_all_versions) && $product.quantity_all_versions > 0)}{l s='Product available with different options'}{else}{l s='Available'}{/if}{/if} 3. Delete the word Available as in {l s='Available'} (there are 2 instances) like this : {if isset($product.available_for_order) && $product.available_for_order && !isset($restricted_country_mode)}{if ($product.allow_oosp || $product.quantity > 0)}{l s=''}{elseif (isset($product.quantity_all_versions) && $product.quantity_all_versions > 0)}{l s='Product available with different options'}{else}{l s=''}{/if}{/if} 4. Save and refresh your webpage.To remove 'availability' on product page :1. open .../themes/your theme/product.tpl2. search for the following codes (in v 1.4.3 default theme its on line 338 to 343) : quantity == 0 && !$product->available_later) OR ($product->quantity != 0 && !$product->available_now) OR !$product->available_for_order OR $PS_CATALOG_MODE} style="display: none;"{/if}> {l s='Availability:'} quantity == 0} class="warning-inline"{/if}> {if $product->quantity == 0}{if $allow_oosp}{$product->available_later}{else}{l s='This product is no longer in stock'}{/if}{else}{$product->available_now}{/if} 3. Uncomment the whole code like this : <!-- quantity == 0 && !$product->available_later) OR ($product->quantity != 0 && !$product->available_now) OR !$product->available_for_order OR $PS_CATALOG_MODE} style="display: none;"{/if}> {l s='Availability:'} quantity == 0} class="warning-inline"{/if}> {if $product->quantity == 0}{if $allow_oosp}{$product->available_later}{else}{l s='This product is no longer in stock'}{/if}{else}{$product->available_now}{/if} --> 4. Save and refresh your webpage.I hope the above help. 1 Link to comment Share on other sites More sharing options...
robkwal Posted July 5, 2011 Author Share Posted July 5, 2011 Thanks Sam, worked a treat!!! Link to comment Share on other sites More sharing options...
rololo88 Posted August 20, 2011 Share Posted August 20, 2011 Is it same procedure with ps 1.4.4 because it doesn't work for me with the original theme i still see "available" Link to comment Share on other sites More sharing options...
mobimob Posted August 30, 2011 Share Posted August 30, 2011 Hi I have the same problem in 1.4.4.1 I have Uncomment the whole code, like Sam says, but it is still htere when I refresh ther site. I have tried other pc's but it is still there, so its not the cache. Can anyone help me remove the Available text?? Thanks in advance. Link to comment Share on other sites More sharing options...
aliaspt Posted October 13, 2011 Share Posted October 13, 2011 How does this work for PS 1.3.1? The code seems to be different from the new PS Link to comment Share on other sites More sharing options...
SpoiledK Posted November 30, 2011 Share Posted November 30, 2011 In version 1.4.6.2 Edit: \themes\yourtheme\css\product_list.css Add: display: none: You final solution should look like this: ul#product_list li span.availability { display: none; color: #488c40; font-size: 0.9em } I hope this helps... 1 Link to comment Share on other sites More sharing options...
adibranch Posted January 6, 2012 Share Posted January 6, 2012 dont forget ! if you are using cache and compile for your site, you wont see any template changes until you clear the files in tools/smarty/compile and tools/smarty/cache Link to comment Share on other sites More sharing options...
Bejo Posted June 26, 2013 Share Posted June 26, 2013 (edited) thx for sharing. fiuh i think can disable that from bo Edited June 26, 2013 by Bejo (see edit history) Link to comment Share on other sites More sharing options...
berta recchia Posted June 28, 2013 Share Posted June 28, 2013 This worked without force compiling on 1.4.6.2. Thank you so much. Link to comment Share on other sites More sharing options...
Mackens Posted December 27, 2013 Share Posted December 27, 2013 Is it possible to remove this text on products list only when the product us not in stock but can still be ordered (ie preorders) ? Link to comment Share on other sites More sharing options...
ALMAJ Posted January 24, 2014 Share Posted January 24, 2014 Is it possible to remove this text on products list only when the product us not in stock but can still be ordered (ie preorders) ? bump Link to comment Share on other sites More sharing options...
Ben90 Posted January 6, 2015 Share Posted January 6, 2015 Is it also working on prestashop 1.6.0.9 ? Link to comment Share on other sites More sharing options...
TheWolf Posted February 18, 2015 Share Posted February 18, 2015 Because i do not use the advanced stock management system and all my items are in stock or should not be a factor in the order process, in order to remove that pesky "In Stock" icon I just edited product-list.tpl and commented out the following : {* {if (!$PS_CATALOG_MODE && $PS_STOCK_MANAGEMENT && ((isset($product.show_price) && $product.show_price) || (isset($product.available_for_order) && $product.available_for_order)))} {if isset($product.available_for_order) && $product.available_for_order && !isset($restricted_country_mode)} <span itemprop="offers" itemscope itemtype="http://schema.org/Offer" class="availability"> {if ($product.allow_oosp || $product.quantity > 0)} <span class="{if $product.quantity <= 0 && !$product.allow_oosp}out-of-stock{else}available-now{/if}"> <link itemprop="availability" href="http://schema.org/InStock" />{if $product.quantity <= 0}{if $product.allow_oosp}{if isset($product.available_later) && $product.available_later}{$product.available_later}{else}{l s='In Stock'}{/if}{else}{l s='Out of stock'}{/if}{else}{if isset($product.available_now) && $product.available_now}{$product.available_now}{else}{l s='In Stock'}{/if}{/if} </span> {elseif (isset($product.quantity_all_versions) && $product.quantity_all_versions > 0)} <span class="available-dif"> <link itemprop="availability" href="http://schema.org/LimitedAvailability" />{l s='Product available with different options'} </span> {else} <span class="out-of-stock"> <link itemprop="availability" href="http://schema.org/OutOfStock" />{l s='Out of stock'} </span> {/if} </span> {/if} {/if} </div> *} Works on 1.6.0.11 Link to comment Share on other sites More sharing options...
secondhand-obchod.sk Posted March 7, 2015 Share Posted March 7, 2015 Hi, I just tried it in 1.6.0.9 and it seems to work. I would like to replace this button "in stock " with another one which shows the product condition: new, used, refurbished. I am not a programmer, could someone tell me how to edit the product-list.tpl (i guess this is where it should be done... )? thx in advance Link to comment Share on other sites More sharing options...
Ben90 Posted March 9, 2015 Share Posted March 9, 2015 Hi, I just tried it in 1.6.0.9 and it seems to work. I would like to replace this button "in stock " with another one which shows the product condition: new, used, refurbished. I am not a programmer, could someone tell me how to edit the product-list.tpl (i guess this is where it should be done... )? thx in advance What if you try this, go to your product item -> quantities -> at the bottom you can see availability setting. You can change displayed text in stock, or when it's out of stock, with your own writing. Link to comment Share on other sites More sharing options...
secondhand-obchod.sk Posted March 9, 2015 Share Posted March 9, 2015 Hi, Thanks for your reply, but actually I was more thinking about using the same button which now shows in stock and automatically write there the product condition. I have found a code somewhere in a forum which i added to my product-list.tpl, just it does not work ... the in stock I have commented out, so it does not show anymore.: {if (!$PS_CATALOG_MODE AND ((isset($product.show_price) && $product.show_price) || (isset($product.available_for_order) && $product.available_for_order)))} <div class="content_price" itemprop="offers" itemscope itemtype="http://schema.org/Offer"> {if isset($product.show_price) && $product.show_price && !isset($restricted_country_mode)} <span itemprop="price" class="price product-price"> {if !$priceDisplay}{convertPrice price=$product.price}{else}{convertPrice price=$product.price_tax_exc}{/if} {if $product.condition} <p id="product_condition"> <label>{l s='Condition'} </label> {if $product.condition == 'new'} <link itemprop="itemCondition" href="http://schema.org/NewCondition"/> <span class="editable">{l s='New'}</span> {elseif $product.condition == 'used'} <link itemprop="itemCondition" href="http://schema.org/UsedCondition"/> <span class="editable">{l s='Used'}</span> {elseif $product.condition == 'refurbished'} <link itemprop="itemCondition" href="http://schema.org/RefurbishedCondition"/> <span class="editable">{l s='Refurbished'}</span> {/if} </p> {/if} </span> <meta itemprop="priceCurrency" content="{$currency->iso_code}" /> {if isset($product.specific_prices) && $product.specific_prices && isset($product.specific_prices.reduction) && $product.specific_prices.reduction > 0} {hook h="displayProductPriceBlock" product=$product type="old_price"} <span class="old-price product-price"> {displayWtPrice p=$product.price_without_reduction} Link to comment Share on other sites More sharing options...
LadyLionheart Posted January 18, 2017 Share Posted January 18, 2017 Because i do not use the advanced stock management system and all my items are in stock or should not be a factor in the order process, in order to remove that pesky "In Stock" icon I just edited product-list.tpl and commented out the following : {* {if (!$PS_CATALOG_MODE && $PS_STOCK_MANAGEMENT && ((isset($product.show_price) && $product.show_price) || (isset($product.available_for_order) && $product.available_for_order)))} {if isset($product.available_for_order) && $product.available_for_order && !isset($restricted_country_mode)} <span itemprop="offers" itemscope itemtype="http://schema.org/Offer" class="availability"> {if ($product.allow_oosp || $product.quantity > 0)} <span class="{if $product.quantity <= 0 && !$product.allow_oosp}out-of-stock{else}available-now{/if}"> <link itemprop="availability" href="http://schema.org/InStock" />{if $product.quantity <= 0}{if $product.allow_oosp}{if isset($product.available_later) && $product.available_later}{$product.available_later}{else}{l s='In Stock'}{/if}{else}{l s='Out of stock'}{/if}{else}{if isset($product.available_now) && $product.available_now}{$product.available_now}{else}{l s='In Stock'}{/if}{/if} </span> {elseif (isset($product.quantity_all_versions) && $product.quantity_all_versions > 0)} <span class="available-dif"> <link itemprop="availability" href="http://schema.org/LimitedAvailability" />{l s='Product available with different options'} </span> {else} <span class="out-of-stock"> <link itemprop="availability" href="http://schema.org/OutOfStock" />{l s='Out of stock'} </span> {/if} </span> {/if} {/if} </div> *} Works on 1.6.0.11 Doesnt seem to work on 1.6.1, any suggestions? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now