WC_Template_Loader::unsupported_theme_single_featured_image_filter()
Prevent the main featured image on product pages because there will be another featured image in the gallery.
Method of the class: WC_Template_Loader{}
No Hooks.
Return
String
.
Usage
$result = WC_Template_Loader::unsupported_theme_single_featured_image_filter( $html );
- $html(string) (required)
- Img element HTML.
Changelog
Since 3.3.0 | Introduced. |
WC_Template_Loader::unsupported_theme_single_featured_image_filter() WC Template Loader::unsupported theme single featured image filter code WC 9.4.2
public static function unsupported_theme_single_featured_image_filter( $html ) { if ( self::in_content_filter() || ! is_product() || ! is_main_query() ) { return $html; } return ''; }