September 16, 2014 at 1:31 pm
Hi Ben,
I am using WooCommerce German Market which adds legally necessary wordings to the shop pages (Actually any german webshop without an own legal department needs it – Otherwise, one can easily get sued by any German lawyer, you can read more about this on *Login to see link
At my shop page at *Login to see link (you should still have the htaccess credentials) I have a product that comes with two variations (250g and 500g). When selecting one of the two variations, then there is an ajax call to admin-ajax.php with the parameters
action update_variation
variation_id 894
The response for this ajax call needs to be inserted and shown (german law is strict about this). The response is:
<span class="woocommerce-de_price_taxrate ">
inkl. 7% MwSt. </span>
<div class="woocommerce_de_versandkosten">
zzgl. <a class="versandkosten" href="*Login to see link
Versand </a>
</div>
This works all fine with other themes, but not with Virtue. Have a look at how it looks with Twenty Thirteen here:
*Login to see link
*Login to see link
You can also see it live in action at *Login to see link where the ajax response is correctly inserted into the HTML DOM.
I searched through the source code and saw that the Virtue theme does add wp-content/themes/virtue_premium/assets/js/add-to-cart-variation-radio.js and wp-content/themes/virtue_premium/assets/js/add-to-cart-variation.js – and thereby possibly overwriting the standard wp-content/plugins/woocommerce/assets/js/frontend/add-to-cart-variation.js? That is something the other working themes don’t do. Maybe this is why the legal wording from the Ajax response does not get included.
We want to go live with our shop by next week, and this is really a show stopper currently…
Kind regards,
Nadine