Filter hook 'post_gallery'
in WP Core File wp-includes/media.php at line 2583
Description
Filters the default gallery shortcode output. If the filtered output isn't empty, it will be used instead of generating the default gallery template.
Occurrences
Filename |
Line Number |
wp-includes/media.php |
2583 |
Parameters
Type |
Name |
Description |
string |
$output |
The gallery output. Default empty. |
array |
$attr |
Attributes of the gallery shortcode. |
int |
$instance |
Unique numeric ID of this gallery shortcode instance. |
PHP Doc
/**
* Filters the default gallery shortcode output.
*
* If the filtered output isn't empty, it will be used instead of generating
* the default gallery template.
*
* @since 2.5.0
* @since 4.2.0 The `$instance` parameter was added.
*
* @see gallery_shortcode()
*
* @param string $output The gallery output. Default empty.
* @param array $attr Attributes of the gallery shortcode.
* @param int $instance Unique numeric ID of this gallery shortcode instance.
*/