-
AuthorPosts
-
June 20, 2013 at 8:48 pm #25123
Hello,
I have no idea where this is in the code or how to do it, but I would greatly appreciate some help on this one.
Basically in Enfold with WooCommerce installed, when you add a product it adds the nice ajax symbol top right of the shopping cart and then you can hover over it and see the items you have added and view cart and checkout.
If you hover over those items you can then click on them and be taken to that product.
Due to the fact I’m building a course website and have used ‘add to cart’ buttons and not actually the product pages. I want it so I can’t click on the items in the cart widget (ajax thing) I want it so people can just use it as a reference to see what’s in their cart and click to checkout or see cart etc..
So in short I just want the items to still show exactly how they are but not hyperlinks or.. clicking on the items takes me straight to the cart and not the product?
Hopefully that makes sense, been trying to find out where it’s putting the link tags then I could properly nut it out, but I’m here as a last resort.
Cheers,
Daniel :)
June 21, 2013 at 5:28 am #125841Hi,
Not sure if this is the one you’re looking for. Add this on your custom.css or Quick CSS. This will disable the link.
.cart_list.product_list_widget li a {
cursor: default;
pointer-events: none !important;
}Regards,
Ismael
June 21, 2013 at 9:00 am #125842Hello Ismrael,
Always with the great replies!
This works great for Firefox and Chrome, though for IE when I hover it doesn’t show but I can still click and be taken through to the item. Is there any way around this for IE or not really?
Cheers mate,
Daniel
June 24, 2013 at 1:48 pm #125843Hi Daniel,
You can use a bit of javascript to unwrap the links. In your js>avia.js file add this line:
$('.cart_list.product_list_widget li a').contents().unwrap();
right after the document ready(function) like this:
$(document).ready(function()
{
$('.cart_list.product_list_widget li a').contents().unwrap();Regards,
Devin
June 24, 2013 at 8:57 pm #125844Hello Devin,
Thanks for the reply, though that didn’t seem to work for IE9? Maybe my IE is buggared. On everything else it’s fine.
Cheers,
Daniel
June 25, 2013 at 7:24 pm #125845I don’t know of any specific reason why it wouldn’t but hopefully that gets you close enough. In the end you may want to look into digging into the woocommerce hooks/filters which is the proper way to do something like this.
Neither of us just happen to know the proper syntax off hand unfortunately .
Regards,
Devin
June 27, 2013 at 12:03 pm #125846Okay, cheers for the update and help. :)
Regards,
Daniel
-
AuthorPosts
- The topic ‘Unlinking the links of the Enfold WooCommerce Dropdown’ is closed to new replies.