Add WooCommerce Quickview Anywhere in your Theme

Let’s face it, your customer’s want to know all about your products as quickly as possible. Offering them a quickview option is the ideal way to solve this issue.

Using our WooCommerce Quickview plugin, you can easily insert a customisable Quickview button on all products in your WooCommerce store. Not only that, but if you’re handy with a bit of code, you can also trigger Quickview from any element in your HTML.

Output a Quickview Button Using PHP

In your PHP template, make sure the global quickview variable is at the top of the file. This gives you access to the Quickview methods.

Then, simply add the following code to output a Quickview button (styled based on the Quickview settings):

Where $product_id is the ID of the product you want to show a Quickview button for.

Add a Quickview Trigger to any HTML Element

You can also add a Quickview trigger to any element by using a data-attribute on your HTML element. For example, to add it to an image:

Again, $product_id is the ID of the product you want to show a Quickview button for. You could also just enter the ID manually, but chances are you want things a little dynamic.

Wrap it up

So there’s a few methods for adding Quickview to anything. It truly is a great tool for any eCommerce store, and you’ve likely seen it in use in many popular themes. For example, our plugin is actually used in the Atelier theme. If you’ve seen it in use elsewhere, or have used it yourself in a premium theme, do let us know – we love to see it in the wild!

Leave a Reply

4 Comments on "Add WooCommerce Quickview Anywhere in your Theme"

avatar
  Subscribe  
newest oldest most voted
Notify of
Laine Kwok
Guest
2 versions of quickviews from iconic and james kemp… I have both installed and 1 cannot activate but keep prompting to active as it mentioned if I don’t update it will affect some of my other plugins 🙁 why is there 2 versions of quickview? which should i use? I am using Cardiinal theme from themeforest. The current WooCommerce Quickview activated is the Version 3.3.2 by James Kemp. The other WooCommerce Quickview that keep prompting to activate is version 3.4.2 by Iconic. When I try to activate it, it will prompt : Fatal error: Cannot redeclare class jckqv in /home/xxx/public_html/xxxshop/wp-content/plugins/jck-woo-quickview/jck-woo-quickview.php… Read more »
Mom Trk
Guest

hi there, I want to add a quick view option on a text!
my website will be an online order food store and my category page will be a list of food. no images
so when someone clicks for example on the word “cheeseburger” it will open the whole product page on that popup
is it possible?

thank you!