Tagged: Cart, icon, woocommerce
-
AuthorPosts
-
May 21, 2017 at 6:41 am #797146
Hi guys,
I have an issue with the cart icon not appearing when running WooCommerce 3.0.7 / Enfold 4.0.7.
Cart icon set to ‘display floating but only once product added to cart’ in Enfold config.
It never appears unless I force it’s position (right:0px). If I include this hack in my custom.css this will mean it shows even when it should be hidden with an empty cart.
Previously reported at https://kriesi.at/support/topic/woocommerce-3-0-1-cart-icon-badge-not-displaying/ but closed without a proper resolution.
- This topic was modified 7 years, 6 months ago by Jason.
May 22, 2017 at 9:10 am #797476Hey Jason,
You need to update the theme to the latest version, that`s 4.0.7
Best regards,
John TorvikMay 22, 2017 at 10:46 am #797526I am running 4.0.7 that was a typo.
Can you please attempt to reproduce this on your end?
Thanks,
JasonMay 22, 2017 at 11:13 am #797544Hi,
I can confirm it’s working well, I have tested on my end using Enfold 4.0.7, Woocommerce 3.0.7 and WordPress 4.7.5. Can you give us a temporary admin access? so we can check further. You can place the login details in Private Content, so it is only visible to the moderators :)
Best regards,
NikkoMay 22, 2017 at 11:39 am #797563The issue only occurs after adding the 2nd item to the cart.
URL in private content.
- This reply was modified 7 years, 6 months ago by Jason. Reason: fix image
May 23, 2017 at 11:35 pm #798594Hi,
I added 50 different products and everything is functioning properly ( only your logo not visible )
Best regards,
BasilisMay 24, 2017 at 1:06 am #798651Can you provide a screenshot? Did you move between pages in between adding to cart? Were using the add-to-cart link from the product grid (as shown in my screenshot) or from individual product pages?
You can see in screenshot that the cart dropdown is set to right: -60px; as it’s off the screen… This is from a new browser session with cache cleared.
- This reply was modified 7 years, 6 months ago by Jason.
May 24, 2017 at 8:40 am #798771I have the same issue, cart icon is not showing up after upgrading to Enfold 4.0.7 and WooCommerce 3. Works fine with WooCommerce 2.x though.
You can check it at http://mondiale.de/testumgebung/de/ and just add something to the cart, i.e. this http://mondiale.de/testumgebung/de/produkt/pruefung-telc-deutsch-a1/
I can force it to always show up by adding this
.cart_dropdown { right: 0px; }
but that’s just a workaround, not a fix.
- This reply was modified 7 years, 6 months ago by mchbeck. Reason: added workaround
May 25, 2017 at 8:42 pm #799778Hi,
@Jason And I actually do not see it now.
Have you removed something?Best regards,
BasilisMay 26, 2017 at 1:31 am #799914I have not changed anything mate. It’s as it was the other day. I am hoping you guys can provide a fix so I can upgrade my Production site to WC3.0. The workaround of forcing the cart icon constantly is a bit ugly.
Cheers,
JasonMay 26, 2017 at 2:17 pm #800138Hi Jason,
The cart icon is invisible until a product is added to it. I tested and the cart icon appeared when I added a product to the cart. If you don’t like this behavior, you can add the code from above to always have the cart visible.
If you need further assistance please let us know.
Best regards,
VictoriaMay 26, 2017 at 2:19 pm #800141Please read above and look at the screenshots. There are multiple people with this problem. Your reply indicates you have not read the thread.
May 26, 2017 at 8:57 pm #800360Hi Jason,
I might have been not very attentive, sorry about that. This issue needs further investigation.
if($cart_pos == "always_display" || (!empty($cart) && !avia_active_caching()))
if(!function_exists('avia_active_caching')) { function avia_active_caching() { if(defined('W3TC') || defined('WPCACHEHOME') || class_exists('HyperCache') || class_exists('\\quick_cache\\plugin')) { return true; } return false; } }
Are you using any caching plugin?
Best regards,
VictoriaMay 27, 2017 at 12:55 am #800467I had a plugin installed but disabled. The WPCACHEHOME variable was still set in my wp-config.php.
Unsetting the variable seems to fix it!?
My production site uses the same caching plugin (WP-Cache Manager) and does not have the same bug running WC 2.6.14 and Enfold 4.0.5.
May 27, 2017 at 4:47 pm #800554Hi Jason,
Well, that’s an old WooCommerce version, there could have been quite a few changes. So you got it working for you, didn’t you?
Best regards,
VictoriaMay 28, 2017 at 1:59 am #800691Let me clarify:
Production – WC 2.6.14 and Enfold 4.0.5 – WORKING
Dev – WC 3.0.7 and Enfold 4.0.7 – BROKENI have provided a Dev URL for you to test on and two other people have reported the same issue.
Please stop trying to dismiss this problem, it’s very frustrating. I paid for the theme and I expect it to work.
May 28, 2017 at 11:35 am #800765Hi Jason,
It seemed to me that after you disabled the caching it worked. Did you unset the variable? Did it work when you unset?
Best regards,
VictoriaMay 28, 2017 at 11:55 am #800770Caching was already disabled, I just unset the variable.
This is not a fix as we obviously need caching in a production scenario. Caching worked with the prior version.
May 28, 2017 at 1:32 pm #800801Hi Jason,
You can put this code to your child theme functions.php
if(!function_exists('avia_woocommerce_cart_pos')) { add_filter( 'avf_header_classes', 'avia_woocommerce_cart_pos' , 10 , 3); function avia_woocommerce_cart_pos($class, $necessary, $prefix) { if($prefix == 'html_') // only for the html tag { global $woocommerce; $cart = $woocommerce->cart->get_cart(); $cart_pos = avia_get_option('cart_icon'); if($cart_pos == "always_display" || !empty($cart)) { $class[] = "visible_cart"; } if($cart_pos == "always_display_menu") { $class[] = "cart_at_menu"; } } return $class; } }
and see if this helps.
Best regards,
VictoriaMay 28, 2017 at 2:23 pm #800810Is this a temporary fix? Will you be fixing this bug in a coming version of Enfold?
May 29, 2017 at 9:48 am #800974Hi there,
Adding Victoria’s code to the functions.php does indeed fix it for me as well.
Jason has a crucial point though: Will this be fixed with the next release? I don’t want to add workaround after workaround to my child theme files, because those workarounds might break something when the next version is released.
Thank you!
May 30, 2017 at 6:27 am #801367Hi,
That filter already exist in the theme but @victoria modified it so that the html classes will still be applied even if there are no caching plugins installed in the theme. Please provide the WP and FTP login details so that we can test your installation further.
Best regards,
IsmaelMay 30, 2017 at 7:01 am #801369Hi,
UPDATE: We were able to reproduce the issue. The cart icon is not displaying if the first option (“Header Shopping Cart Icon”) is selected in the “Header Shopping Cart Icon” settings and when the page is refresh. Please remove the filter then edit the config-woocommerce > woocommerce-mod.js. Replace it with the following script.
// https://pastebin.com/FKgHQhuK
Please remove browser cache or hard refresh after the modification.
Best regards,
IsmaelMay 30, 2017 at 7:53 am #801385Thank you, will test it soon.
The question remains though: Will this be fixed with the next release?
May 30, 2017 at 8:15 am #801394Hi,
If the solution above works then it’s going to be included in the next update. We already reported the issue to Kriesi.
Best regards,
IsmaelMay 30, 2017 at 8:21 am #801395That’s good news!
I just tested it and can confirm that it works :)
Thank you, Ismael.
May 30, 2017 at 10:52 pm #801698Hi,
Glad to hear that. Thanks for using Enfold :)
Best regards,
NikkoJuly 26, 2017 at 9:25 pm #830345It is still not working after upgrading to 4.1.2
July 30, 2017 at 10:28 am #831778Still broken for me with 4.1.2 also.
Can we please get a confirmation as to when this will be fixed in the theme release?
I can’t upgrade from 4.0.7 until you fix this bug. It’s been months.
Thanks,
Jason- This reply was modified 7 years, 3 months ago by Jason.
August 2, 2017 at 6:48 am #833198 -
AuthorPosts
- The topic ‘WooCommerce Cart Icon Broken – WooCommerce 3 / Enfold 4’ is closed to new replies.