use_default_gallery_style filter-hookWP 3.1.0

Filters whether to print default gallery styles.

Usage

add_filter( 'use_default_gallery_style', 'wp_kama_use_default_gallery_style_filter' );

/**
 * Function for `use_default_gallery_style` filter-hook.
 * 
 * @param bool $print Whether to print default gallery styles. Otherwise, defaults to true.
 *
 * @return bool
 */
function wp_kama_use_default_gallery_style_filter( $print ){

	// filter...
	return $print;
}
$print(true|false)
Whether to print default gallery styles. Otherwise, defaults to true.
Default: false if the theme supports HTML5 galleries

Changelog

Since 3.1.0 Introduced.

Where the hook is called

gallery_shortcode()
use_default_gallery_style
wp-includes/media.php 2456
if ( apply_filters( 'use_default_gallery_style', ! $html5 ) ) {

Where the hook is used in WordPress

Usage not found.