WC_Template_Loader::unsupported_theme_single_featured_image_filter( string $html )

Prevent the main featured image on product pages because there will be another featured image in the gallery.


Description Description


Parameters Parameters

$html

(Required) Img element HTML.


Top ↑

Return Return

(string)


Top ↑

Source Source

File: includes/class-wc-template-loader.php

	public static function unsupported_theme_single_featured_image_filter( $html ) {
		if ( self::in_content_filter() || ! is_product() || ! is_main_query() ) {
			return $html;
		}

		return '';
	}

Top ↑

Changelog Changelog

Changelog
Version Description
3.3.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.