WordPress Release: 4.2.0
Tag Name: 4.2.0
Release Date: 4/23/2015
WordPressWorld's most popular open-source content management system powering over 40% of all websites. Offers extensive plugin ecosystem, themes, and robust community support for blogs, e-commerce, and corporate websites. Highly customizable and scalable platform suitable for beginners and advanced developers.
TL;DR
WordPress 4.2 "Powell" introduces significant improvements to the publishing experience with emoji support, theme switching in the customizer, plugin updates without page reload, and improved accessibility. This release focuses on making WordPress more expressive, responsive, and accessible for all users while enhancing the overall publishing workflow.
Highlight of the Release
- Native emoji support across all platforms
- Theme switching directly in the customizer
- Plugin updates without page reload ('shiny updates')
- Improved Press This tool for quick content sharing
- Enhanced accessibility with landmark roles and keyboard navigation
- Dismissible admin notices
- Extended character support for non-Latin languages
Migration Guide
Emoji Support
If your theme or plugin manipulates content directly, you may need to ensure it properly handles emoji characters. WordPress automatically processes emoji in standard content flows, but custom code that bypasses standard filters may need updating.
Theme Customizer Changes
If you've built custom theme customizer experiences, review the changes to the customizer API, particularly around theme switching functionality. Some hooks and filters have been renamed for consistency.
Plugin Update Hooks
For plugins that interact with the plugin update process, note that the update flow has changed with the introduction of shiny updates. New JavaScript events are available for detecting update status:
wp-plugin-installingwp-plugin-install-successwp-plugin-install-error
Renamed Filters
Several filters have been renamed for consistency:
get_media_embedded_in_content_allowedis nowmedia_embedded_in_content_allowed_typespre_wp_prepare_themes_for_jsis nowpre_prepare_themes_for_js
Review your code if you're using these filters and update accordingly.
Upgrade Recommendations
Recommended for All Users
WordPress 4.2 is a recommended upgrade for all users. The improvements to the publishing experience, theme management, and plugin updates provide significant benefits for all WordPress sites.
Testing Recommendations
Before upgrading production sites:
- Test your themes and plugins in a staging environment
- Pay special attention to any custom code that handles content display or manipulates the database directly
- If you use custom theme customizer implementations, verify they work correctly with the new theme switching functionality
Database Changes
This release includes improvements to database handling, particularly for extended character sets. While the upgrade process handles these changes automatically, it's always a good practice to back up your database before upgrading.
Plugin Compatibility
Most plugins should work without issues, but those that interact deeply with the editor, customizer, or plugin update process may need updates. Check for plugin updates before or immediately after upgrading WordPress.
Bug Fixes
TinyMCE Editor Fixes
- Fixed caret position issues after replacing emoji in Chrome on Windows
- Fixed editor undo levels in wpView
- Fixed issues with creating previews when pasting embeddable URLs in Firefox
- Fixed problems with empty paragraphs after adding image captions
Database and Query Handling
- Fixed handling of UTF-8MB4 character sets when the connection doesn't support it
- Improved handling of numerical keys in
add_query_arg() - Fixed issues with
sanitize_sql_orderby()edge cases - Corrected handling of term slugs with UTF-8 characters in post classes
UI and Display Issues
- Fixed invalid HTML markup in the Customizer Theme Switcher
- Fixed focus styling issues in various admin components
- Corrected display of avatars and emoji in dashboard recent comments
- Fixed issues with the media modal on narrow screens
- Resolved problems with spinners and their positioning
Accessibility Improvements
- Fixed keyboard events and callbacks for the Themes screen search field
- Improved focus management in modals and overlays
- Corrected ARIA attributes in various admin components
Multisite Fixes
- Fixed handling of email address updates for existing users
- Improved handling of global terms synchronization
- Prevented plugins from unintentionally switching sites
New Features
Emoji Support
WordPress now includes native emoji support, allowing users to use colorful emoji characters in posts, pages, and comments. The feature works across all platforms and browsers by automatically converting emoji characters to image representations, ensuring consistent display regardless of the visitor's device.
Theme Switching in Customizer
The customizer now includes a powerful theme browsing and switching experience. Users can browse installed themes, preview them live, and switch themes without leaving the customizer interface, creating a more seamless theme management workflow.
Shiny Updates
Plugin updates now happen without a full page reload. This "shiny updates" feature provides a smoother experience when updating plugins, with progress indicators and success messages displayed inline.
Improved Press This
The Press This bookmarklet has been completely redesigned with a new interface that makes it easier to quickly share content from around the web. It now features better content detection and a more streamlined publishing experience.
Extended Character Support
WordPress now offers better support for non-Latin text with improved handling of UTF-8 characters in database operations. This enhances the publishing experience for users writing in languages that use extended character sets.
Complex Query Ordering
Developers can now create more sophisticated queries with multiple ORDER BY statements, allowing for more complex content organization and display options.
Security Updates
Improved SQL Query Sanitization
Enhanced sanitization of SQL queries, particularly for ORDER BY clauses, to prevent potential SQL injection vulnerabilities.
Better Escaping of Theme Version Numbers
Theme version numbers are now properly escaped when displayed, preventing potential XSS vulnerabilities.
Improved Post Title Escaping
Post titles are now correctly escaped on the Dashboard, addressing potential security issues with maliciously crafted titles.
Enhanced File Handling
Improved security checks for file handling operations during updates and installations.
Performance Improvements
Faster Plugin Updates
The new "shiny updates" feature not only improves the user experience but also makes plugin updates more efficient by eliminating full page reloads.
Improved Database Query Performance
Several optimizations have been made to database queries:
- Better handling of collation checks for improved performance
- Quick return for queries that will never return user data
- Optimized handling of ASCII-only queries
Lazy Loading Theme Screenshots
Theme screenshots in the customizer are now lazy-loaded, improving the initial load time of the theme browsing interface, especially for users with many themes installed.
Optimized Emoji Processing
The emoji processing has been implemented with performance in mind, using efficient JavaScript to handle the conversion of emoji characters to images without significant overhead.
Impact Summary
WordPress 4.2 "Powell" represents a significant step forward in making WordPress more expressive, user-friendly, and accessible. The addition of emoji support brings WordPress in line with modern communication trends, while the improved theme switching experience in the customizer makes theme management more intuitive and visual.
The "shiny updates" feature dramatically improves the plugin update experience, eliminating frustrating page reloads and providing better feedback during the update process. This, combined with the improved FTP credential modal, makes site maintenance smoother and less disruptive.
For content creators, the revamped Press This tool offers a faster way to share and publish content from around the web. Developers benefit from more powerful query capabilities and better handling of extended character sets, opening up new possibilities for content organization and multilingual sites.
Accessibility improvements throughout the admin interface ensure WordPress continues to be usable by everyone, with better keyboard navigation, focus management, and ARIA landmark roles.
Overall, WordPress 4.2 delivers meaningful improvements to the publishing workflow while addressing numerous bugs and performance issues, making it a worthwhile upgrade for all WordPress users.
