/ Published in: PHP

Going through the templates and removing really isn’t an ideal solution here. Luckily there is a single function you can add to your child theme’s functions.php file that will disable this.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
/* Remove the default WooCommerce 3 JSON/LD structured data */ function remove_output_structured_data() { remove_action( 'wp_footer', array( WC()->structured_data, 'output_structured_data' ), 10 ); // This removes structured data from all frontend pages remove_action( 'woocommerce_email_order_details', array( WC()->structured_data, 'output_email_structured_data' ), 30 ); // This removes structured data from all Emails sent by WooCommerce } add_action( 'init', 'remove_output_structured_data' );
URL: https://www.prodjex.com/2018/04/remove-the-woocommerce-json-ld-structured-data-format/
Comments
