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

#   Variant published by default is not working

##

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

Less More

- Posts: 24
- Thank you received: 1
-
-

11 years 4 months ago [\#205017](#205017) by [maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")  *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205017 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")* was created by *[maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")*

-- HikaShop version -- : 2.5.0
-- Joomla version -- : 3.4.1
-- PHP version -- : 5.4.36

Options "Variant published by default" is not working. Products always display with variant by default if option set as Yes or No.

The following user(s) said Thank You: [A. van de Kamp](/forum/user/7683-a-van-de-kamp "View A. van de Kamp's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84Nzc1ODAtdmFyaWFudC1wdWJsaXNoZWQtYnktZGVmYXVsdC1pcy1ub3Qtd29ya2luZz90bXBsPW1hcmtkb3du) 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 [\#205022](#205022) by [Xavier](/forum/user/4105-xavier "View Xavier's Profile")  Replied by *[Xavier](/forum/user/4105-xavier "View Xavier's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205022 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

Hi,

Yes indeed this option is no more used, the variant system has changed, now you have to create your variants, they are no more generated automatically so when adding new variants you can publish or unpublish them directly in the listing from the product edition page.

We will see to add back that feature or remove the option definitively. Thanks for the report.

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

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

Less More

- Posts: 24
- Thank you received: 1
-
-

11 years 4 months ago [\#205118](#205118) by [maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")  Replied by *[maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205118 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

The problem is that I want to that no option is not displayed by default. But I can not do it in backend. Besides that on click by checkmark "published" nothing happens.

- [ ![screen2.png](/forum/attachment/24939) ](/forum/attachment/24939 "screen2.png") [ ](/forum/attachment/24939?download=1 "screen2.png")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS84Nzc1ODAtdmFyaWFudC1wdWJsaXNoZWQtYnktZGVmYXVsdC1pcy1ub3Qtd29ya2luZz90bXBsPW1hcmtkb3du) 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 [\#205124](#205124) by [Xavier](/forum/user/4105-xavier "View Xavier's Profile")  Replied by *[Xavier](/forum/user/4105-xavier "View Xavier's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205124 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

Hi,

Yes my bad, you have to click on the variant to open its edition and then unpublish it thanks to the option.

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

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

Less More

- Posts: 24
- Thank you received: 1
-
-

11 years 4 months ago [\#205238](#205238) by [maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")  Replied by *[maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205238 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

Ok. I'm understand with option published.
But I want that no one variant not published by default. How can i do this?

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

Less More

- Posts: 86290
- Thank you received: 14268
-
-

11 years 4 months ago [\#205273](#205273) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205273 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

Hi,

Can you try to change the line: Code:

' SELECT '.$p_code.' as c_product_code, '. $this-&gt;database-&gt;Quote('variant') .','. (int)$product_id . ',1,' . $t . ',' . $t . ',' . $this-&gt;database-&gt;Quote(@$element-&gt;product_group_after_purchase) .

to: Code:

' SELECT '.$p_code.' as c_product_code, '. $this-&gt;database-&gt;Quote('variant') .','. (int)$product_id . ',0,' . $t . ',' . $t . ',' . $this-&gt;database-&gt;Quote(@$element-&gt;product_group_after_purchase) .

in the file administrator/components/com_hikashop/classes/product.php and see if that helps ?

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

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

Less More

- Posts: 24
- Thank you received: 1
-
-

11 years 4 months ago [\#205399](#205399) by [maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")  Replied by *[maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205399 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

It's not work

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

Less More

- Posts: 86290
- Thank you received: 14268
-
-

11 years 4 months ago [\#205757](#205757) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205757 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

Hi,

I've done a test on my end with that same modification and it works. Variants are created unpublished by default when you create them in the Variants tab of the new HikaShop product edition interface.
I don't see why that wouldn't work. Can you double check ?

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

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

Less More

- Posts: 24
- Thank you received: 1
-
-

11 years 4 months ago [\#205867](#205867) by [maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")  Replied by *[maclen2007](/forum/user/37123-maclen2007 "View maclen2007's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205867 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

Finally it received. My mistake was that when I'm choose the characteristic, I'm not filled value by default and tab variants not exist. And I could not guess intuitively.

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

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26394
- Thank you received: 4078
-
- [](http://obsi.dev)
-

11 years 4 months ago [\#205877](#205877) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[Variant published by default is not working](/forum/26-product-category-display/877580-variant-published-by-default-is-not-working#205877 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.1 -- PHP version -- : 5.4.36  Options &quot;Variant published by default&quot; is not working. Products always display with variant by default if option set as Yes or No.")*

Hi,

In the variant listing, you have a column for the "default" where you can see the default variant.
So if in the list there is none variant with the green tick, it means that your default variant does not exist (and you have to choose one in the current list)

When with the old interface you had to read the default variant configuration in one page and check it is exists in the variant listing, with the new interface you can see that directly in the listing.
But we will see to add a little message above the variant listing when there is no default variant in the list.

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

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

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

[](#top)
