apply_filters( 'media_upload_default_tab', string $tab )
- Since
- 2.5.0
Filters the default tab in the legacy (pre-3.5.0) media popup.
Compatibility
- WordPress
- since 2.5.0
- 6.7.7
- 6.8.8
- 6.9.7
- 7.0.4
- 7.1.0
Present in every tracked release (6.7.7 to 7.1.0).
Parameters
$tabstring- The default media popup tab. Default 'type' (From Computer).
Where this hook fires · 2
wp-admin/includes/media.php:90the_media_upload_tabs()wp-admin/media-upload.php:78file scope
Source code
* Filters the default tab in the legacy (pre-3.5.0) media popup. * * @since 2.5.0 * * @param string $tab The default media popup tab. Default 'type' (From Computer). */ $tab = apply_filters( 'media_upload_default_tab', 'type' );} $body_id = 'media-upload'; // Let the action code decide how to handle the request.if ( 'type' === $tab || 'type_url' === $tab || ! array_key_exists( $tab, media_upload_tabs() ) ) {Changelog
Introduced in 2.5.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
About this page
- Parsed data
- Generated from the wordpress-develop 6.9.7 tag, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
- Corrections
- Something wrong on this page? Report it and it gets fixed in the next regeneration.