Home › Forums › WordPress Themes – Premium › Lavish Pro › Disable Zoom on single product Woocommerce
Hello , i want to disable zoom effect on single product page in woocommerce .I did try many ways but still not working .Any idea how to disable this ?
Hi Peter,
Check out this plugin, it will provide you with options to do that
https://wordpress.org/plugins/woo-product-image-gallery-options/
regards
Imre
Please do add this code on child theme functions.php file to remove zooming effect and woocommerce support for zooom effect
/**
* @return remove woocommerce zoom script
*/
add_action( 'wp_head', 'lavish_child_remove_parent_scripts' );
function lavish_child_remove_parent_scripts() {
wp_dequeue_script( 'lavish-bootstrap' );
}
/**
* @return remove woocommerce support for zooming effect
*/
add_action( 'after_setup_theme', 'lavish_child_remove_woocommerce_support', 20 );
function lavish_child_remove_woocommerce_support() {
remove_theme_support( 'wc-product-gallery-zoom' );
remove_theme_support( 'wc-product-gallery-lightbox' );
remove_theme_support( 'wc-product-gallery-slider' );
}
Note: You can keep the woocommerce support for light boz and slider just by removing this code from above functions:
remove_theme_support( 'wc-product-gallery-lightbox' );
remove_theme_support( 'wc-product-gallery-slider' );
Let us know how it goes for you.
Thanks
`
With our premium themes, we offer access to site documentation, video tutorials and timely support. Even if you have just started on WordPress, our support staff have the patience to help you create appealing sites gracefully.
Company
Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.To find out more, including how to control cookies, see here: Privacy Policy
© Copyright © 2023 Styled Themes. All Right Reserved.