wp_get_audio_extensions() WordPress Function
The wp_get_audio_extensions() function retrieves a list of supported audio file extensions. This function can be used by plugins and themes to determine which audio files can be used on a site.
wp_get_audio_extensions() #
Returns a filtered list of supported audio formats.
Return
(string[]) Supported audio formats.
Source
File: wp-includes/media.php
function wp_get_audio_extensions() { /** * Filters the list of supported audio formats. * * @since 3.6.0 * * @param string[] $extensions An array of supported audio formats. Defaults are * 'mp3', 'ogg', 'flac', 'm4a', 'wav'. */ return apply_filters( 'wp_audio_extensions', array( 'mp3', 'ogg', 'flac', 'm4a', 'wav' ) ); }
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
Version | Description |
---|---|
3.6.0 | Introduced. |