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

#   Removing Product option removes price

##

- **[ltempest](/forum/user/1784-ltempest "View ltempest's Profile")**
- [![ltempest's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1784-ltempest "View ltempest's Profile") Topic Author
- [ Offline](/forum/user/1784-ltempest)

Less More

- Posts: 237
- Thank you received: 5
-
-

3 years 1 month ago [\#355834](#355834) by [ltempest](/forum/user/1784-ltempest "View ltempest's Profile")  *[Removing Product option removes price](/forum/26-product-category-display/907124-removing-product-option-removes-price#355834 "-- HikaShop version -- : 5.0.0 -- Joomla version -- : 4.3.4 -- PHP version -- : 8.2  Hello, I have a product setup for Gift Wrap with two characteristics, Gift wrap / No Gift Wrap. once has a cost the other does not.  I have numeorus products on my site with three variants of size setup each with their own price.  In the 'root' product I have added the Gift Wrap product as an Option.  When viewing on the frontend, the product is displayed and I can change the variant and see a different price. I can also add / remove the Gift wrap option which chnages the price. All works fine.  However I now want to remove the Gift wrap option. I have tried to unpublish the Gift Wrap product, remove it as an option from the 3 variant product, but everything I try whent he gift wrap is not included the variant product price stops being displayed or added to the cart.  Examples:  As you can see if you change the varaint of the product the price displayed changes, ad gift wrap etc all works, but on the second link nothing is shown price wise?  How do you remove the Option and still show the variant pricing?  Thanks Lee")* was created by *[ltempest](/forum/user/1784-ltempest "View ltempest's Profile")*

-- HikaShop version -- : 5.0.0
-- Joomla version -- : 4.3.4
-- PHP version -- : 8.2

Hello,
I have a product setup for Gift Wrap with two characteristics, Gift wrap / No Gift Wrap. once has a cost the other does not.

I have numeorus products on my site with three variants of size setup each with their own price.

In the 'root' product I have added the Gift Wrap product as an Option.

When viewing on the frontend, the product is displayed and I can change the variant and see a different price. I can also add / remove the Gift wrap option which chnages the price. All works fine.

However I now want to remove the Gift wrap option. I have tried to unpublish the Gift Wrap product, remove it as an option from the 3 variant product, but everything I try whent he gift wrap is not included the variant product price stops being displayed or added to the cart.

Examples:

[ Product with Gift Wrap options](https://cotsperf.under-development.info/shop-online/ladies-fragrances/product/pallas-eau-de-parfum)

[ Product with Gift Wrap options removed](https://cotsperf.under-development.info/shop-online/ladies-fragrances/product/english-rose-eau-de-parfum)

As you can see if you change the varaint of the product the price displayed changes, ad gift wrap etc all works, but on the second link nothing is shown price wise?

How do you remove the Option and still show the variant pricing?

Thanks
Lee

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS85MDcxMjQtcmVtb3ZpbmctcHJvZHVjdC1vcHRpb24tcmVtb3Zlcy1wcmljZT90bXBsPW1hcmtkb3du) 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")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86584
- Thank you received: 14325
-
-

3 years 1 month ago [\#355836](#355836) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Removing Product option removes price](/forum/26-product-category-display/907124-removing-product-option-removes-price#355836 "-- HikaShop version -- : 5.0.0 -- Joomla version -- : 4.3.4 -- PHP version -- : 8.2  Hello, I have a product setup for Gift Wrap with two characteristics, Gift wrap / No Gift Wrap. once has a cost the other does not.  I have numeorus products on my site with three variants of size setup each with their own price.  In the 'root' product I have added the Gift Wrap product as an Option.  When viewing on the frontend, the product is displayed and I can change the variant and see a different price. I can also add / remove the Gift wrap option which chnages the price. All works fine.  However I now want to remove the Gift wrap option. I have tried to unpublish the Gift Wrap product, remove it as an option from the 3 variant product, but everything I try whent he gift wrap is not included the variant product price stops being displayed or added to the cart.  Examples:  As you can see if you change the varaint of the product the price displayed changes, ad gift wrap etc all works, but on the second link nothing is shown price wise?  How do you remove the Option and still show the variant pricing?  Thanks Lee")*

Hi,

Check the product with options page on our demo website:
[ demo.hikashop.com/index.php/en/hikashop/...ct-page/with-options](https://demo.hikashop.com/index.php/en/hikashop/product-page/with-options)
As you can see, there are two prices:
- the price without options
- the price with options
When a product doesn't have options, only the price without options is displayed.
What you're describing indicates that you've removed the display of the price without options, so that only the price with options is displayed. Which means that for products without options, no price is displayed.

So the issue is a customization issue. You'll have to modify the show_default view file in order to add back the code you deleted and which is responsible for the display of the price without options on the product details page:
[ i.imgur.com/U6befiD.png](https://i.imgur.com/U6befiD.png)Code:

&lt;!-- PRICE --&gt; &lt;?php $itemprop_offer = 'itemprop="offers" itemscope itemtype="https://schema.org/Offer"'; ?&gt; &lt;span id="hikashop_product_price_main" class="hikashop_product_price_main" &lt;?php echo $itemprop_offer; ?&gt;&gt; &lt;?php $main =&amp; $this-&gt;element; if(!empty($this-&gt;element-&gt;main)) $main =&amp; $this-&gt;element-&gt;main; if(!empty($main-&gt;product_condition) &amp;&amp; !empty($this-&gt;element-&gt;prices)) { ?&gt; &lt;meta itemprop="itemCondition" itemtype="https://schema.org/OfferItemCondition" content="https://schema.org/&lt;?php echo $main-&gt;product_condition; ?&gt;" /&gt; &lt;?php } if($this-&gt;params-&gt;get('show_price') &amp;&amp; (empty($this-&gt;displayVariants['prices']) &#124;&#124; $this-&gt;params-&gt;get('characteristic_display') != 'list')) { $this-&gt;row =&amp; $this-&gt;element; $this-&gt;setLayout('listing_price'); echo $this-&gt;loadTemplate(); $price = 0; if (!empty($this-&gt;element-&gt;prices)) { $price = $this-&gt;itemprop_price; } } ?&gt; &lt;meta itemprop="price" content="&lt;?php echo $price; ?&gt;" /&gt; &lt;meta itemprop="availability" content="https://schema.org/&lt;?php echo ($this-&gt;row-&gt;product_quantity != 0) ? 'InStock' : 'OutOfstock' ;?&gt;" /&gt; &lt;meta itemprop="priceCurrency" content="&lt;?php echo $this-&gt;currency-&gt;currency_code; ?&gt;" /&gt; &lt;/span&gt; &lt;!-- EO PRICE --&gt;

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

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

- **[ltempest](/forum/user/1784-ltempest "View ltempest's Profile")**
- [![ltempest's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/1784-ltempest "View ltempest's Profile") Topic Author
- [ Offline](/forum/user/1784-ltempest)

Less More

- Posts: 237
- Thank you received: 5
-
-

3 years 1 month ago [\#355846](#355846) by [ltempest](/forum/user/1784-ltempest "View ltempest's Profile")  Replied by *[ltempest](/forum/user/1784-ltempest "View ltempest's Profile")* on topic *[Removing Product option removes price](/forum/26-product-category-display/907124-removing-product-option-removes-price#355846 "-- HikaShop version -- : 5.0.0 -- Joomla version -- : 4.3.4 -- PHP version -- : 8.2  Hello, I have a product setup for Gift Wrap with two characteristics, Gift wrap / No Gift Wrap. once has a cost the other does not.  I have numeorus products on my site with three variants of size setup each with their own price.  In the 'root' product I have added the Gift Wrap product as an Option.  When viewing on the frontend, the product is displayed and I can change the variant and see a different price. I can also add / remove the Gift wrap option which chnages the price. All works fine.  However I now want to remove the Gift wrap option. I have tried to unpublish the Gift Wrap product, remove it as an option from the 3 variant product, but everything I try whent he gift wrap is not included the variant product price stops being displayed or added to the cart.  Examples:  As you can see if you change the varaint of the product the price displayed changes, ad gift wrap etc all works, but on the second link nothing is shown price wise?  How do you remove the Option and still show the variant pricing?  Thanks Lee")*

Nicolas,
Thanks for the reply, awesome that works, I did not think to look at my template override!

Awesome.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS85MDcxMjQtcmVtb3ZpbmctcHJvZHVjdC1vcHRpb24tcmVtb3Zlcy1wcmljZT90bXBsPW1hcmtkb3du) 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.049 seconds

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