tribe_doing_shortcode( null|string $tag = null )
Check whether a specific shortcode is being run.
This is limited to only shortcodes registered with Tribe\Shortcode\Manager.
Parameters
- $tag
-
(null|string) (Optional) The shortcode tag name, or null to check if doing any shortcode.
Default value: null
Return
(bool) Whether the shortcode is currently being run.
Source
File: src/functions/template-tags/general.php
function tribe_doing_shortcode( $tag = null ) { return tribe( 'shortcode.manager' )->is_doing_shortcode( $tag ); }
Changelog
Version | Description |
---|---|
4.12.10 | Introduced. |