get_shortcode_tags_in_content
get_shortcode_tags_in_content ( $content )
Parameters:- (string) content The content to check.
Returns:- (string[]) An array of registered shortcode names found in the content.
Defined at: - Introduced in WordPress: 6.3.2
- Deprecated in WordPress: —
Description
Returns a list of registered shortcode names found in the given content.Example usage:
get_shortcode_tags_in_content( '[audio src="file.mp3"][/audio] [foo] [gallery ids="1,2,3"]' );
// array( 'audio', 'gallery' )