• Resolved devworlds

    (@devworlds)


    Hi,

    i’m trying to change some line of codes for product-images.php file.

    i move original file to my child theme. after change it not changing.

    can you guide me plz.

    thank you

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support fizanzvai

    (@fizanzvai)

    Hi,

    Thanks for getting back to us. Please follow the following steps-

    1. Create a folder called ‘woocommerce’ inside the theme’s root area. If a folder “woocommerce” already exists skip this step.

    2. Copy the edited product-images.php and paste it inside the newly created folder ‘woocommerce’

    3. Add the below snippet inside the theme’s functions.php file:

    function edit_wvg_gallery_template($template, $template_name, $old_template){
    if ( $template_name == 'single-product/product-image.php' ) {
    $template = get_theme_file_path() . '/woocommerce/product-images.php';
    }
    return $template;
    }
    add_filter('woo_variation_gallery_gallery_template_override_location', 'edit_wvg_gallery_template', 40, 3);

    Hope to hear from you soon.

    Thank You

    Thread Starter devworlds

    (@devworlds)

    Hi,

    Thanks its working.

    thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.