Howdy! This is Last Week in WordPress Core Core is the set of software required to run WordPress. The Core Development Team builds WordPress. for the week of February 24—March 2! Lots of activity for the past week, which is great as we head into our last few days of alpha. Please join us for daily triage at 1900 UTC to help work through the remaining enhancements scheduled for 3.9.
As a quick note, if you work with our tools in ‘develop’, and are receiving a SELF_SIGNED_CERT_IN_CHAIN
error, you can resolve it by running npm config set ca=""
. For details, check out this npm blog post.
If you want to skim, each section is roughly ordered by an important and/or interesting factor.
Editor
- Add the ability to drag and drop files directly onto the editor. Upon drop, the media manager will open, and file will begin to upload. [27343] #19845
- Throttle scrolling of the main window when the editor is active and is being scrolled with the mouse wheel or a trackpad. [27368]. Expect some major tweaks here, though; see #27013.
Templating
- Introduce HTML5 gallery support. When a theme supports HTML5 galleries via
add_theme_support( 'html5', 'gallery' )
, figure
, and figcaption
will be used instead of definition list markup. [27302] #26697
- Add a filter Filters are one of the two types of Hooks https://codex.wordpress.org/Plugin_API/Hooks. They provide a way for functions to modify data of other functions. They are the counterpart to Actions. Unlike Actions, filters are meant to work in an isolated manner, and should never have side effects such as affecting global variables and output. to remove or rename page templates for a theme. This does not yet handle adding page templates. [27297] #13265
- Move
comment-reply.js
to the footer. While it can function before the page is loaded, it works by moving the comment form, which is usually toward the bottom of the page. Please report any contraindications on the ticket Created for both bug reports and feature development on the bug tracker.. [27303] #12641
- Return 404 when querying author’s posts who is not a member and has no posts on the site. [27290] #20601
- Make
get_adjacent_post()
wrap a new WP_Adjacent_Post
object that uses WP_Query
. [27285] [27286] #26937
- Add
exclude
and include
arguments to wp_list_authors()
. [27274] #9902
Internals
- Multisite Used to describe a WordPress installation with a network of multiple blogs, grouped by sites. This installation type has shared users tables, and creates separate database tables for each blog (wp_posts becomes wp_0_posts). See also network, blog, site: Introduce
get_site_by_path()
and further rewrite the site detection process for multisite. This makes it so that a sunrise plugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party could do much of its work by adding filters, if those are even needed. [27359] #27003
- Database: Use MySQLi for WordPress development versions, regardless of PHP The web scripting language in which WordPress is primarily architected. WordPress requires PHP 7.4 or higher version, to increase testing footprint. There’s also a constant for testing purposes. [27257] [27278] #21663
- Plugin API An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways.: Introduce
doing_filter()
and doing_action()
to identify hooks In WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same. in progress. You can also use this with to identify a hook that has completed. For more, see [27294] #14994.
- Formatting: Strip backslashes, not just forward slashes, from
untrailingslashit()
. trailingslashit()
will now remove any forward or backslashes from the end of a string before appending a forward slash. [27344] #22267
- Date/Time: Allow
current_time()
to accept a date format string, adding to timestamp
and mysql
. [27259] #21653
- Updates: During core upgrade, copy wp-includes/version.php over last, to avoid an installation failing with the new version.php in place. [27336] #25860
- Rewrite API: Allow rewrite endpoints to specify a query variable name. [27327] #20905
- Cache API: Revert [27115] and let cache backends handle the stripping of spaces in cache keys as necessary.
microtime()
returns greater precision than microtime(true)
. [27300] #27000, #23448, #26903, #14485
- Query: Add a
$default
argument to get_query_var()
and WP_Query::get()
. Helpful when working with endpoints. [27304] #16471
- Comment Query: Allow
user_id
to be an array of IDs in WP_Comment_Query
. [27258] #27064
- Users: Make the user arguments for
get_edit_profile_url()
and get_dashboard_url()
optional, defaulting to the current user. [27260] [27265] #16686
External Libraries
- Update the Masonry JavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. library to version 3. [27271] #25351
- The new script handle is
masonry
. The old jquery-masonry
handle is the official shiv that sits on top of the v3 library to be backwards compatible with v2 usage. While v3 no longer depends on jQuery, a theme or plugin may have been implicitly loading jQuery though Masonry, rather than additionally declaring it as a dependency for themselves.
- Themes should switch to
masonry
and declare jQuery as a dependency on their own if they need it.
- Upgrade guide on Masonry’s site, with the exception that, for core, we continue to include
imagesLoaded
.
- Upgrade Plupload to 2.x (2.1.1) [27316] #25663
- Update the Root Certificate bundle used for SSL Secure Sockets Layer. Provides a secure means of sending data over the internet. Used for authenticated and private actions. communication by
WP_HTTP
from the latest Mozilla release NSS. [27307] #27017
Developer Tools
- Add
grunt-patch-wordpress
for applying patches directly from Trac An open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress.. Mapped to grunt patch
, which declares usage. Requires npm install
to install. [27299] #27023
- Add JSHint to Travis CI config. [27267] #26446
For the complete list of commits to trunk A directory in Subversion containing the latest development code in preparation for the next major release cycle. If you are running "trunk", then you are on the latest revision., check out the log on Trac. Interested in joining in? Write or test a patch for 3.9.
Thanks to @adamsilverstein, @andy, @avryl, @bassgang, @bootsz, @chrisscott, @danielbachhuber, @DrewAPicture, @enej, @ericlewis, @ericmann, @ethitter, @evarlese, @garyc40, @GaryJ, @gcorne, @georgestephanis, @GregLone, @helen, @iamfriendly, @Ipstenu, @jackreichert, @jeremyfelt, @johnjamesjacoby, @jorbin, @knutsp, @kovshenin, @kpdesign, @leewillis77, @markjaquith, @mattheu, @mboynes, @mitchoyoshitaka, @mjbanks, @mordauk, @morganestes, @nacin, @nicolealleyinteractivecom, @obenland, @ocean90, @patricknami, @pento, @pross, @rickalee, @salcode, @scribu, @SergeyBiryukov, @shelob9, @siobhyb, @solarissmoke, @xsonic, @stephcook22, @theorboman, @tivnet, @TobiasBg, @willmot, @wonderboymusic, @xknown, and @yoavf for their help this week!
#3-9, #week-in-core