Title: Version 4.0
Author: Subrata Sarkar
Published: March 13, 2019

---

# Version 4.0

## In this article

 * [Highlights](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#highlights)
 * [What’s New](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#whats-new)
    - [General](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#general)
    - [Posts](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#posts)
    - [Media](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#media)
    - [Comments](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#comments)
    - [Plugins](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#plugins)
    - [Accessibility](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#accessibility)
    - [Install Process](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#install-process)
    - [Multisite](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#multisite)
 * [Under The Hood](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#under-the-hood)
    - [General](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#general-2)
    - [JavaScript](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#javascript)
    - [Bug Fixes](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#bug-fixes)
    - [Multisite](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#multisite-2)
    - [Classes](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#classes)
    - [Functions](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#functions)
    - [Actions & Filters](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#actions-filters)
    - [Constants](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#constants)
    - [External Libraries](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#external-libraries)

[ Back to top](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#wp--skip-link--target)

On September 4, 2014, WordPress **Version 4.0** “Benny,” named for jazz musician
Benny Goodman, was released to the public. For more information on this enhancement
and bug-fix release, read the [WordPress Blog](https://wordpress.org/news/), and
see the [Changelog for 4.0](https://codex.wordpress.org/Changelog/4.0).

For **Version 4.0**, the database version (**db_version** in **wp_options**) changed
to 29630, and the [Trac](https://core.trac.wordpress.org/) revision was 29710.

 * [View Closed Tickets](https://trac.wordpress.org/query?status=closed&milestone=4.0)

## 󠀁[Highlights](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#highlights)󠁿

 * **Manage your media and embedded content with style**
    - [Explore your uploads](https://codex.wordpress.org/Media_Library_Screen) in
      a beautiful, endless grid
    - A new details preview makes viewing and editing any amount of media in sequence
      a snap.
 * **The content-editing experience is better than ever**
    - The visual editor now expands to fit your content
    - A fixed toolbar in the editor when you scroll
    - Embeddable content previews right in the visual editor
 * **Better workflow for finding and installing plugins**
    - A new grid view adds some visual flair to [finding and installing plugins](https://codex.wordpress.org/Plugins_Add_New_Screen),
      bringing relevant plugin info front and center
 * **For Developers**
    - Customizer Panels API
    - Updated external libraries
    - Better flexibility for [WP_Query](https://codex.wordpress.org/Class_Reference/WP_Query)
      [ORDER BY](https://codex.wordpress.org/Class_Reference/WP_Query#Order_.26_Orderby_Parameters)

## 󠀁[What’s New](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#whats-new)󠁿

### 󠀁[General](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#general)󠁿

 * Featured image previews now support .bmp files
 * Featured Image meta box is now hidden for contributors lacking upload capabilities
 * New supported [oEmbed](https://codex.wordpress.org/Embeds) providers: CollegeHumor,
   Issuu, Mixcloud, YouTube playlists, TED talks
 * [Install WordPress](https://codex.wordpress.org/Installing_WordPress) in your
   language
 * Streamlined Language management right [from the dashboard](https://codex.wordpress.org/Settings_General_Screen)

### 󠀁[Posts](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#posts)󠁿

 * Display embed previews for audio/visual URLs in Visual editor content box.
 * Page scrolling now scrolls post content box.
 * Edit Post/Page menu bar sticks to top of content box when scrolling (Visual and
   Text editor).
 * Color picker was re-added to the Visual editor

### 󠀁[Media](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#media)󠁿

 * Add Media Grid view option (default) for [Media Library](https://codex.wordpress.org/Media_Library_Screen)
 * Add “Bulk Select” button to Media Grid view to delete multiple items
 * Add [oEmbed support](https://codex.wordpress.org/Embeds) for TED talks, Mixcloud,
   CollegeHumor.com, Issuu
 * Expand oEmbed support to include YouTube playlist URLs and Polldaddy’s short 
   URL format
 * Remove Viddler oEmbed support
 * Update SlideShare oEmbed regex
 * Improved media experience on small screen sizes (embedded videos now responsive)
 * Native video and audio shortcodes now support Flash playback looping

### 󠀁[Comments](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#comments)󠁿

 * Comments in trash can now be marked as spam.

### 󠀁[Plugins](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#plugins)󠁿

 * Display plugins list as grid, with thumbnails, on [Add New screen](https://codex.wordpress.org/Plugins_Add_New_Screen).
 * Add popup window with plugin details (displays info from plugin’s directory page).
 * Add “Beta Testing” tab to Plugins screen for new features-as-plugins.

### 󠀁[Accessibility](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#accessibility)󠁿

 * Improved keyboard accessibility in the Add Media panel
 * Improved screen-reader support for Customizer sections
 * Makes links in help tabs keyboard accessible
 * Improvements for screen-readers when managing widgets in the Customizer

### 󠀁[Install Process](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#install-process)󠁿

 * Add language select menu as first Installation screen (skipped for localized 
   installs)

### 󠀁[Multisite](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#multisite)󠁿

 * mp4 file extension was added to allowed upload file types

## 󠀁[Under The Hood](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#under-the-hood)󠁿

### 󠀁[General](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#general-2)󠁿

 * Performance and effectiveness improvements to wptexturize()
 * Ensure custom post types nested under top-level menu items get the proper classes
 * Added a src parameter to the embed shortcode
 * Fixes for handling nested shortcodes
 * Make default ‘template’ argument of [the_taxonomies()](https://codex.wordpress.org/Function_Reference/the_taxonomies)
   and [get_the_taxonomies()](https://codex.wordpress.org/Function_Reference/get_the_taxonomies)
   translatable
 * Remove a redundant condition for comment feeds from [WP_Query::get_posts()](https://codex.wordpress.org/Class_Reference/WP_Query)
 * The Customizer now properly honors theme support defaults for background images
 * Installed Themes search now shows a proper “no results” message
 * Improved, more consistent styling for HTML5 input elements
 * Post previews now redirect to the permalink if the post has been published
 * Email and URL input types have been implemented where appropriate in the admin
 * Most uses of extract() have been removed from the core code
 * 3gp mime type support was added
 * [wp_handle_upload|sideload()](https://codex.wordpress.org/Function_Reference/wp_handle_upload)
   logic was consolidated
 * Remove dead and unused code from dashboard.php following changes in [3.8](https://codex.wordpress.org/Version_3.8)
 * The operator argument now case-insensitive in tax queries
 * Now possible to disable drag and drop functionality in [wp_editor()](https://codex.wordpress.org/Function_Reference/wp_editor)
   instances
 * Trigger _doing_it_wrong() when a registered post type or taxonomy slug is too
   long (20 characters max)
 * Widgets management in the Customizer to leverage the new Panels API.

### 󠀁[JavaScript](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#javascript)󠁿

 * Heartbeat API “experimental” labels have now been removed
 * Improved inline documentation for Media Views
 * Forces an autosave on switch from Visual to Text editor

### 󠀁[Bug Fixes](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#bug-fixes)󠁿

 * Fix a notice with media attached to non-existent post type
 * Fix expanding and collapsing the admin menu on small screen sizes
 * Fix a bug where multiple Add Media buttons shared an ID attribute
 * Fix [get_the_ID()](https://codex.wordpress.org/Function_Reference/get_the_ID)
   not checking for a proper post object
 * Fix current track highlighting in audio playlists
 * Fixed bug with audio player not properly floating around images in the editor
 * Fix a bug where bulk actions would be performed upon clicking the Filter button
   in some circumstances
 * Fix [remove_all_filters()](https://codex.wordpress.org/Function_Reference/remove_all_filters)
   always returning true via [has_filter()](https://codex.wordpress.org/Function_Reference/has_filter)
   in some scenarios
 * Fix a notice in [wp_reschedule_event](https://codex.wordpress.org/Function_Reference/wp_reschedule_event)
 * Fix paragraph tags not being converted in PressThis for the Text editor
 * Fix [get_the_excerpt()](https://codex.wordpress.org/Function_Reference/get_the_excerpt)
   not always checking $post->post_excerpt
 * Introduce caching for oEmbed responses
 * Fix an issue where attachment display settings didn’t work for galleries
 * Leverage iframe sandboxing for audio and video, allowing arbitrary scripts to
   be loaded
 * Ensure all plugins have an accurate oEmbed provider list by loading them “just
   in time”
 * Fixed several problems with formatting of curly quotes, square braces, non-breaking
   spaces, and related performance issues.

### 󠀁[Multisite](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#multisite-2)󠁿

 * Fix a bug where an incorrect schema was shown on the Edit Site screen

### 󠀁[Classes](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#classes)󠁿

#### 󠀁[What’s New](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#whats-new-2)󠁿

 * Introduce WP_Customize_Panel
 * Introduce WP_Session_Tokens
 * Introduce WP_User_Meta_Session_Tokens

 * Introduce [WP_Query::parse_orderby()](https://codex.wordpress.org/Class_Reference/WP_Query)
 * Introduce [WP_Query::parse_order()](https://codex.wordpress.org/Class_Reference/WP_Query)
 * Introduce [wpdb::esc_like()](https://codex.wordpress.org/Class_Reference/wpdb)

 * Introduce WP_oEmbed::get_provider()
 * Introduce WP_oEmbed::_add_provider_early()
 * Introduce WP_oEmbed::_remove_provider_early()

 * Introduce [WP_Customize_Control::active()](https://codex.wordpress.org/Class_Reference/WP_Customize_Control)
 * Introduce [WP_Customize_Control::active_callback()](https://codex.wordpress.org/Class_Reference/WP_Customize_Control)
 * Introduce [WP_Customize_Control::input_attrs()](https://codex.wordpress.org/Class_Reference/WP_Customize_Control)
 * Introduce [WP_Customize_Control::active_callback()](https://codex.wordpress.org/Class_Reference/WP_Customize_Control)
 * Introduce WP_Widget_Area_Customize_Control::active_callback()

 * Introduce [WP_Customize_Manager::containers()](https://codex.wordpress.org/Class_Reference/WP_Customize_Manager)
 * Introduce [WP_Customize_Manager::panels()](https://codex.wordpress.org/Class_Reference/WP_Customize_Manager)
 * Introduce [WP_Customize_Manager::customize_preview_override_404_status()](https://codex.wordpress.org/Class_Reference/WP_Customize_Manager)
 * Introduce [WP_Customize_Manager::add_panel()](https://codex.wordpress.org/Class_Reference/WP_Customize_Manager)
 * Introduce [WP_Customize_Manager::get_panel()](https://codex.wordpress.org/Class_Reference/WP_Customize_Manager)
 * Introduce [WP_Customize_Manager::remove_panel()](https://codex.wordpress.org/Class_Reference/WP_Customize_Manager)

 * Introduce [WP_Customize_Widgets::is_widget_rendered()](https://codex.wordpress.org/Class_Reference/WP_Customize_Widgets)
 * Introduce [WP_Customize_Widgets::is_sidebar_rendered()](https://codex.wordpress.org/Class_Reference/WP_Customize_Widgets)

 * Introduce [WP_Image_Editor::get_quality()](https://codex.wordpress.org/Class_Reference/WP_Image_Editor)
 * Introduce [WP_Dependencies::recurse_deps()](https://codex.wordpress.org/Class_Reference/WP_Dependencies)
 * Introduce WP_Plugin_Install_List_Table::get_installed_plugin_slugs()
 * Introduce magic methods for:
    - Custom_Image_Header
    - Custom_Background** [Walker](https://codex.wordpress.org/Class_Reference/Walker)
    - WP_Ajax_Response
    - WP_Comment_Query
    - [WP_Error](https://codex.wordpress.org/Class_Reference/WP_Error)
    - WP_Filesystem_Base
    - [WP_List_Table](https://codex.wordpress.org/Class_Reference/WP_List_Table)
    - WP_MatchesMapRegex
    - [WP_Object_Cache](https://codex.wordpress.org/Class_Reference/WP_Object_Cache)
    - WP_oEmbed
    - [WP_Query](https://codex.wordpress.org/Class_Reference/WP_Query)
    - WP_Text_Diff_Renderer_Table
    - WP_Roles
    - [WP_User_Query](https://codex.wordpress.org/Class_Reference/WP_User_Query)

### 󠀁[Functions](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#functions)󠁿

#### 󠀁[What’s New](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#whats-new-3)󠁿

 * [WP_Query](https://codex.wordpress.org/Class_Reference/WP_Query) – Better flexibility
   in multiple `orderby` fields
 * [wp_list_pluck()](https://codex.wordpress.org/Function_Reference/wp_list_pluck)–
   $index_key parameter added.

 * Introduce [attachment_url_to_postid()](https://developer.wordpress.org/reference/functions/attachment_url_to_postid/)
 * Introduce [get_comments_number_text()](https://developer.wordpress.org/reference/functions/get_comments_number_text/)
 * Introduce [get_editor_stylesheets()](https://developer.wordpress.org/reference/functions/get_editor_stylesheets/)
 * Introduce [is_customize_preview()](https://developer.wordpress.org/reference/functions/is_customize_preview/)
 * Introduce [translations_api()](https://developer.wordpress.org/reference/functions/translations_api/)
 * Introduce [upgrade_400()](https://developer.wordpress.org/reference/functions/upgrade_400/)
 * Introduce [wp_ajax_set_attachment_thumbnail()](https://developer.wordpress.org/reference/functions/wp_ajax_set_attachment_thumbnail/)
 * Introduce [wp_ajax_parse_embed()](https://developer.wordpress.org/reference/functions/wp_ajax_parse_embed/)
 * Introduce [wp_can_install_language_pack()](https://developer.wordpress.org/reference/functions/wp_can_install_language_pack/)
 * Introduce [wp_destroy_all_sessions()](https://developer.wordpress.org/reference/functions/wp_destroy_all_sessions/)
 * Introduce [wp_destroy_current_session()](https://developer.wordpress.org/reference/functions/wp_destroy_current_session/)
 * Introduce [wp_destroy_other_sessions()](https://developer.wordpress.org/reference/functions/wp_destroy_other_sessions/)
 * Introduce [wp_download_language_pack()](https://developer.wordpress.org/reference/functions/wp_download_language_pack/)
 * Introduce [wp_dropdown_languages()](https://developer.wordpress.org/reference/functions/wp_dropdown_languages/)
 * Introduce [wp_embed_handler_youtube()](https://developer.wordpress.org/reference/functions/wp_embed_handler_youtube/)
 * Introduce [wp_get_all_sessions()](https://developer.wordpress.org/reference/functions/wp_get_all_sessions/)
 * Introduce [wp_get_available_translations()](https://developer.wordpress.org/reference/functions/wp_get_available_translations/)
 * Introduce [wp_get_session_token](https://developer.wordpress.org/reference/functions/wp_get_session_token/)
 * Introduce [wp_install_language_form()](https://developer.wordpress.org/reference/functions/wp_install_language_form/)
 * Introduce [wpview_media_sandbox_styles()](https://developer.wordpress.org/reference/functions/wpview_media_sandbox_styles/)
 * Introduce [wp_spaces_regexp()](https://developer.wordpress.org/reference/functions/wp_spaces_regexp/)
 * Introduce [wp_validate_boolean()](https://developer.wordpress.org/reference/functions/wp_validate_boolean/)

#### 󠀁[Deprecated](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#deprecated)󠁿

 * get_all_category_ids() – use get_terms() instead.
 * like_escape() – use [$wpdb->esc_like()](https://codex.wordpress.org/Class_Reference/wpdb/esc_like)
   instead.
 * url_is_accessable_via_ssl()

### 󠀁[Actions & Filters](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#actions-filters)󠁿

 * The ISO date standard YYYY-MM-DD format was added to the date_formats filter.
 * The $post parameter was added to preview_post_link.
 * wp_handle_upload_prefilter was renamed to {$action}_prefilter.

#### 󠀁[New Actions](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#new-actions)󠁿

 * Introduce [customize_render_panel](https://developer.wordpress.org/reference/hooks/customize_render_panel/)
 * Introduce [customize_render_panel_{$this->id}](https://developer.wordpress.org/reference/hooks/customize_render_panel_this-id/)
 * Introduce [delete_user_form](https://developer.wordpress.org/reference/hooks/delete_user_form/)
 * Introduce [pre_get_users](https://developer.wordpress.org/reference/hooks/pre_get_users/)
 * Introduce [rss_tag_pre](https://developer.wordpress.org/reference/hooks/rss_tag_pre/)

#### 󠀁[New Filters](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#new-filters)󠁿

 * Introduce [async_update_translation](https://developer.wordpress.org/reference/hooks/async_update_translation/)
 * Introduce [attach_session_information](https://developer.wordpress.org/reference/hooks/attach_session_information/)
 * Introduce [customize_control_active](https://developer.wordpress.org/reference/hooks/customize_control_active/)
 * Introduce [human_time_diff](https://developer.wordpress.org/reference/hooks/human_time_diff/)
 * Introduce [oembed_remote_get_args](https://developer.wordpress.org/reference/hooks/oembed_remote_get_args/)
 * Introduce [oembed_ttl](https://developer.wordpress.org/reference/hooks/oembed_ttl/)
 * Introduce [run_wptexturize](https://developer.wordpress.org/reference/hooks/run_wptexturize/)
 * Introduce [session_token_manager](https://developer.wordpress.org/reference/hooks/session_token_manager/)
 * Introduce [term_search_min_chars](https://developer.wordpress.org/reference/hooks/term_search_min_chars/)
 * Introduce [translations_api](https://developer.wordpress.org/reference/hooks/translations_api/)
 * Introduce [translations_api_result](https://developer.wordpress.org/reference/hooks/translations_api_result/)
 * Introduce [wp_editor_expand](https://developer.wordpress.org/reference/hooks/wp_editor_expand/)
 * Introduce [wp_editor_settings](https://developer.wordpress.org/reference/hooks/wp_editor_settings/)
 * Introduce [wp_embed_handler_youtube](https://developer.wordpress.org/reference/hooks/wp_embed_handler_youtube/)
 * Introduce [wp_list_comments_args](https://developer.wordpress.org/reference/hooks/wp_list_comments_args/)
 * Introduce [wp_spaces_regexp](https://developer.wordpress.org/reference/hooks/wp_spaces_regexp/)
 * Introduce [wp_title_parts](https://developer.wordpress.org/reference/hooks/wp_title_parts/)
 * Introduce [wxr_export_skip_commentmeta](https://developer.wordpress.org/reference/hooks/wxr_export_skip_commentmeta/)

### 󠀁[Constants](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#constants)󠁿

#### 󠀁[Deprecated](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#deprecated-2)󠁿

 * FORCE_SSL_LOGIN – use FORCE_SSL_ADMIN instead.
 * WPLANG (see [https://core.trac.wordpress.org/changeset/29630](https://core.trac.wordpress.org/changeset/29630))

### 󠀁[External Libraries](https://wordpress.org/documentation/wordpress-version/version-4-0/?output_format=md#external-libraries)󠁿

 * Update to TinyMCE 4.1.3
 * Update to jQuery 1.11.1
 * Update to MediaElement 2.15

First published

March 13, 2019

Last updated