[Skip to main content](#vessel-content)

#   Pas de produit affiche "désolé déjà vendu"

##

- **[recupart](/forum/user/22376-recupart "View recupart's Profile")**
- [![recupart's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar22376.jpg)](/forum/user/22376-recupart "View recupart's Profile") Topic Author
- [ Offline](/forum/user/22376-recupart)

Less More

- Posts: 20
- Thank you received: 0
-
-
-
- [](http://galerie-vintage.com/)
-

11 years 4 months ago [\#203649](#203649) by [recupart](/forum/user/22376-recupart "View recupart's Profile")  *[Pas de produit affiche "désolé déjà vendu"](/forum/5-support-en-francais-french-support-/877318-pas-de-produit-affiche-desole-deja-vendu#203649 "-- url of the page with the problem -- :   galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20  -- HikaShop version -- : essential -- Joomla version -- : 2.5.28  Bonjour, dans les fiches produit affichage &quot;reversed&quot; j'ai ajouté au product / show&#95;reversed.php  element-&gt;product&#95;quantity == 0){ echo 'Désolé déjà vendu'; } ?&gt; Mais je ne vois pas comment faire disparaître alors le prix...  Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place &quot;Désolé déjà vendu&quot; Merci pour votre aide. Pierre.")* was created by *[recupart](/forum/user/22376-recupart "View recupart's Profile")*

-- url of the page with the problem -- : [ galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20](http://galerie-vintage.com/index.php/product/74-APPLIQUES%20BAROVIER%20ET%20TOSO%20)
-- HikaShop version -- : essential
-- Joomla version -- : 2.5.28

Bonjour,
dans les fiches produit affichage "reversed"
j'ai ajouté au product / show_reversed.php

&lt;?php
//LAYOUT listing_price
if($this-&gt;element-&gt;product_quantity == 0){
echo '&lt;strong&gt;&lt;span style="color:#f00;"&gt;Désolé déjà vendu&lt;/span&gt;&lt;/strong&gt;&lt;br/&gt;';
}
?&gt;
Mais je ne vois pas comment faire disparaître alors le prix...

Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place "Désolé déjà vendu"
Merci pour votre aide.
Pierre.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzUtc3VwcG9ydC1lbi1mcmFuY2Fpcy1mcmVuY2gtc3VwcG9ydC0vODc3MzE4LXBhcy1kZS1wcm9kdWl0LWFmZmljaGUtZGVzb2xlLWRlamEtdmVuZHU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Xavier](/forum/user/4105-xavier "View Xavier's Profile")**
- [![Xavier's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar4105.png)](/forum/user/4105-xavier "View Xavier's Profile")
- [ Offline](/forum/user/4105-xavier)

Less More

- Posts: 13201
- Thank you received: 2322
-
-
-
- [](http://www.kidiweb.fr)
-

11 years 4 months ago [\#203652](#203652) by [Xavier](/forum/user/4105-xavier "View Xavier's Profile")  Replied by *[Xavier](/forum/user/4105-xavier "View Xavier's Profile")* on topic *[Pas de produit affiche "désolé déjà vendu"](/forum/5-support-en-francais-french-support-/877318-pas-de-produit-affiche-desole-deja-vendu#203652 "-- url of the page with the problem -- :   galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20  -- HikaShop version -- : essential -- Joomla version -- : 2.5.28  Bonjour, dans les fiches produit affichage &quot;reversed&quot; j'ai ajouté au product / show&#95;reversed.php  element-&gt;product&#95;quantity == 0){ echo 'Désolé déjà vendu'; } ?&gt; Mais je ne vois pas comment faire disparaître alors le prix...  Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place &quot;Désolé déjà vendu&quot; Merci pour votre aide. Pierre.")*

Bonjour,

Le code affichant le prix est: Code:

if ($this-&gt;params-&gt;get('show_price')) { $this-&gt;row = &amp; $this-&gt;element; $this-&gt;setLayout('listing_price'); echo $this-&gt;loadTemplate(); }

Donc il faut ajouter votre "if / else" autour de ce code.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzUtc3VwcG9ydC1lbi1mcmFuY2Fpcy1mcmVuY2gtc3VwcG9ydC0vODc3MzE4LXBhcy1kZS1wcm9kdWl0LWFmZmljaGUtZGVzb2xlLWRlamEtdmVuZHU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[recupart](/forum/user/22376-recupart "View recupart's Profile")**
- [![recupart's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar22376.jpg)](/forum/user/22376-recupart "View recupart's Profile") Topic Author
- [ Offline](/forum/user/22376-recupart)

Less More

- Posts: 20
- Thank you received: 0
-
-
-
- [](http://galerie-vintage.com/)
-

11 years 4 months ago [\#203744](#203744) by [recupart](/forum/user/22376-recupart "View recupart's Profile")  Replied by *[recupart](/forum/user/22376-recupart "View recupart's Profile")* on topic *[Pas de produit affiche "désolé déjà vendu"](/forum/5-support-en-francais-french-support-/877318-pas-de-produit-affiche-desole-deja-vendu#203744 "-- url of the page with the problem -- :   galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20  -- HikaShop version -- : essential -- Joomla version -- : 2.5.28  Bonjour, dans les fiches produit affichage &quot;reversed&quot; j'ai ajouté au product / show&#95;reversed.php  element-&gt;product&#95;quantity == 0){ echo 'Désolé déjà vendu'; } ?&gt; Mais je ne vois pas comment faire disparaître alors le prix...  Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place &quot;Désolé déjà vendu&quot; Merci pour votre aide. Pierre.")*

Code:

&lt;?php //LAYOUT listing_price if($this-&gt;element-&gt;product_quantity == 0){ echo '&lt;strong&gt;&lt;span style="color:#f00;"&gt;Désolé déjà vendu&lt;/span&gt;&lt;/strong&gt;&lt;br/&gt;'; } else ($this-&gt;params-&gt;get('show_price')) { $this-&gt;row = &amp; $this-&gt;element; $this-&gt;setLayout('listing_price'); echo $this-&gt;loadTemplate(); } ?&gt;

Comme ça?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzUtc3VwcG9ydC1lbi1mcmFuY2Fpcy1mcmVuY2gtc3VwcG9ydC0vODc3MzE4LXBhcy1kZS1wcm9kdWl0LWFmZmljaGUtZGVzb2xlLWRlamEtdmVuZHU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Xavier](/forum/user/4105-xavier "View Xavier's Profile")**
- [![Xavier's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar4105.png)](/forum/user/4105-xavier "View Xavier's Profile")
- [ Offline](/forum/user/4105-xavier)

Less More

- Posts: 13201
- Thank you received: 2322
-
-
-
- [](http://www.kidiweb.fr)
-

11 years 4 months ago [\#203753](#203753) by [Xavier](/forum/user/4105-xavier "View Xavier's Profile")  Replied by *[Xavier](/forum/user/4105-xavier "View Xavier's Profile")* on topic *[Pas de produit affiche "désolé déjà vendu"](/forum/5-support-en-francais-french-support-/877318-pas-de-produit-affiche-desole-deja-vendu#203753 "-- url of the page with the problem -- :   galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20  -- HikaShop version -- : essential -- Joomla version -- : 2.5.28  Bonjour, dans les fiches produit affichage &quot;reversed&quot; j'ai ajouté au product / show&#95;reversed.php  element-&gt;product&#95;quantity == 0){ echo 'Désolé déjà vendu'; } ?&gt; Mais je ne vois pas comment faire disparaître alors le prix...  Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place &quot;Désolé déjà vendu&quot; Merci pour votre aide. Pierre.")*

Bonjour,

Plutôt comme ça: Code:

if($this-&gt;element-&gt;product_quantity == 0){ echo '&lt;strong&gt;&lt;span style="color:#f00;"&gt;Désolé déjà vendu&lt;/span&gt;&lt;/strong&gt;&lt;br/&gt;'; }else if ($this-&gt;params-&gt;get('show_price')) { $this-&gt;row = &amp; $this-&gt;element; $this-&gt;setLayout('listing_price'); echo $this-&gt;loadTemplate(); }

The following user(s) said Thank You: [recupart](/forum/user/22376-recupart "View recupart's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzUtc3VwcG9ydC1lbi1mcmFuY2Fpcy1mcmVuY2gtc3VwcG9ydC0vODc3MzE4LXBhcy1kZS1wcm9kdWl0LWFmZmljaGUtZGVzb2xlLWRlamEtdmVuZHU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[recupart](/forum/user/22376-recupart "View recupart's Profile")**
- [![recupart's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar22376.jpg)](/forum/user/22376-recupart "View recupart's Profile") Topic Author
- [ Offline](/forum/user/22376-recupart)

Less More

- Posts: 20
- Thank you received: 0
-
-
-
- [](http://galerie-vintage.com/)
-

11 years 4 months ago [\#203829](#203829) by [recupart](/forum/user/22376-recupart "View recupart's Profile")  Replied by *[recupart](/forum/user/22376-recupart "View recupart's Profile")* on topic *[Pas de produit affiche "désolé déjà vendu"](/forum/5-support-en-francais-french-support-/877318-pas-de-produit-affiche-desole-deja-vendu#203829 "-- url of the page with the problem -- :   galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20  -- HikaShop version -- : essential -- Joomla version -- : 2.5.28  Bonjour, dans les fiches produit affichage &quot;reversed&quot; j'ai ajouté au product / show&#95;reversed.php  element-&gt;product&#95;quantity == 0){ echo 'Désolé déjà vendu'; } ?&gt; Mais je ne vois pas comment faire disparaître alors le prix...  Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place &quot;Désolé déjà vendu&quot; Merci pour votre aide. Pierre.")*

Parfait!!!!
Merci ![;)](/media/kunena/emoticons/24.png ";)")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzUtc3VwcG9ydC1lbi1mcmFuY2Fpcy1mcmVuY2gtc3VwcG9ydC0vODc3MzE4LXBhcy1kZS1wcm9kdWl0LWFmZmljaGUtZGVzb2xlLWRlamEtdmVuZHU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[recupart](/forum/user/22376-recupart "View recupart's Profile")**
- [![recupart's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar22376.jpg)](/forum/user/22376-recupart "View recupart's Profile") Topic Author
- [ Offline](/forum/user/22376-recupart)

Less More

- Posts: 20
- Thank you received: 0
-
-
-
- [](http://galerie-vintage.com/)
-

11 years 4 months ago [\#203830](#203830) by [recupart](/forum/user/22376-recupart "View recupart's Profile")  Replied by *[recupart](/forum/user/22376-recupart "View recupart's Profile")* on topic *[Pas de produit affiche "désolé déjà vendu"](/forum/5-support-en-francais-french-support-/877318-pas-de-produit-affiche-desole-deja-vendu#203830 "-- url of the page with the problem -- :   galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20  -- HikaShop version -- : essential -- Joomla version -- : 2.5.28  Bonjour, dans les fiches produit affichage &quot;reversed&quot; j'ai ajouté au product / show&#95;reversed.php  element-&gt;product&#95;quantity == 0){ echo 'Désolé déjà vendu'; } ?&gt; Mais je ne vois pas comment faire disparaître alors le prix...  Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place &quot;Désolé déjà vendu&quot; Merci pour votre aide. Pierre.")*

Dans le même ordre d'idée:
Quand il n'y a qu'un seul exemplaire en vente j'ai

1 item in stock
et puisque c'est ce que j'ai choisi le petit rectangle d’incrément.

j'ai déjà un

if($this-&gt;row-&gt;product_quantity&gt;1)

dans le listing price.
Comment supprimer aussi ici cette notion de quantité quand je n'ai qu'un seul exemplaire?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzUtc3VwcG9ydC1lbi1mcmFuY2Fpcy1mcmVuY2gtc3VwcG9ydC0vODc3MzE4LXBhcy1kZS1wcm9kdWl0LWFmZmljaGUtZGVzb2xlLWRlamEtdmVuZHU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86320
- Thank you received: 14276
-
-

11 years 4 months ago [\#203861](#203861) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Pas de produit affiche "désolé déjà vendu"](/forum/5-support-en-francais-french-support-/877318-pas-de-produit-affiche-desole-deja-vendu#203861 "-- url of the page with the problem -- :   galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20  -- HikaShop version -- : essential -- Joomla version -- : 2.5.28  Bonjour, dans les fiches produit affichage &quot;reversed&quot; j'ai ajouté au product / show&#95;reversed.php  element-&gt;product&#95;quantity == 0){ echo 'Désolé déjà vendu'; } ?&gt; Mais je ne vois pas comment faire disparaître alors le prix...  Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place &quot;Désolé déjà vendu&quot; Merci pour votre aide. Pierre.")*

Vous pouvez ajouter le code: Code:

if($this-&gt;row-&gt;product_quantity==1 &amp;&amp; $this-&gt;params-&gt;get('show_quantity_field') !=0){ $this-&gt;params-&gt;set('show_quantity_field',0); }

après le code: Code:

if($this-&gt;config-&gt;get('show_quantity_field') == -2) $this-&gt;params-&gt;set('show_quantity_field', @$this-&gt;row-&gt;product_display_quantity_field);

dans le fichier "quantity".

The following user(s) said Thank You: [recupart](/forum/user/22376-recupart "View recupart's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzUtc3VwcG9ydC1lbi1mcmFuY2Fpcy1mcmVuY2gtc3VwcG9ydC0vODc3MzE4LXBhcy1kZS1wcm9kdWl0LWFmZmljaGUtZGVzb2xlLWRlamEtdmVuZHU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[recupart](/forum/user/22376-recupart "View recupart's Profile")**
- [![recupart's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar22376.jpg)](/forum/user/22376-recupart "View recupart's Profile") Topic Author
- [ Offline](/forum/user/22376-recupart)

Less More

- Posts: 20
- Thank you received: 0
-
-
-
- [](http://galerie-vintage.com/)
-

11 years 4 months ago [\#203865](#203865) by [recupart](/forum/user/22376-recupart "View recupart's Profile")  Replied by *[recupart](/forum/user/22376-recupart "View recupart's Profile")* on topic *[Pas de produit affiche "désolé déjà vendu"](/forum/5-support-en-francais-french-support-/877318-pas-de-produit-affiche-desole-deja-vendu#203865 "-- url of the page with the problem -- :   galerie-vintage.com/index.php/product/74...OVIER%20ET%20TOSO%20  -- HikaShop version -- : essential -- Joomla version -- : 2.5.28  Bonjour, dans les fiches produit affichage &quot;reversed&quot; j'ai ajouté au product / show&#95;reversed.php  element-&gt;product&#95;quantity == 0){ echo 'Désolé déjà vendu'; } ?&gt; Mais je ne vois pas comment faire disparaître alors le prix...  Je souhaite en fait que si la quantité est 0 alors pas de prix affiché et à la place &quot;Désolé déjà vendu&quot; Merci pour votre aide. Pierre.")*

et je supprime X_ITEM_IN_STOCK
à la ligne $text = JText::sprintf(' ', $this-&gt;row-&gt;product_quantity);
Que c'est beau comme ça...
Merci.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzUtc3VwcG9ydC1lbi1mcmFuY2Fpcy1mcmVuY2gtc3VwcG9ydC0vODc3MzE4LXBhcy1kZS1wcm9kdWl0LWFmZmljaGUtZGVzb2xlLWRlamEtdmVuZHU/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.111 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)

[](#top)
