wp_get_video_extensions

Returns a filtered list of WP-supported video formats.

Description

(array) wp_get_video_extensions(); 

Returns (array)

List of supported video formats.


Usage

  1. if ( !function_exists( 'wp_get_video_extensions' ) ) { 
  2. require_once ABSPATH . WPINC . '/media.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = wp_get_video_extensions(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/wp-includes/media.php  
  1. function wp_get_video_extensions() { 
  2. /** 
  3. * Filters the list of supported video formats. 
  4. * @since 3.6.0 
  5. * @param array $extensions An array of support video formats. Defaults are 
  6. * 'mp4', 'm4v', 'webm', 'ogv', 'wmv', 'flv'. 
  7. */ 
  8. return apply_filters( 'wp_video_extensions', array( 'mp4', 'm4v', 'webm', 'ogv', 'wmv', 'flv' ) );