Files
wordpress/wp-includes/version.php
Weston Ruter e40914625b General: Introduce output buffering for template enhancements.
This introduces an output buffer for the entire template rendering process. This allows for post-processing of the complete HTML output via filtering before it is sent to the browser. This is primarily intended for performance optimizations and other progressive enhancements. Extenders must not rely on output buffer processing for critical content and functionality since a site may opt out of output buffering for the sake of streaming. Extenders are heavily encouraged to use the HTML API as opposed to using regular expressions in output buffer filters. 

* A new `wp_before_include_template` action is introduced, which fires immediately before the template file is included. This is useful on its own, as it avoids the need to misuse `template_include` filter to run logic right before the template is loaded (e.g. sending a `Server-Timing` header).
* The `wp_start_template_enhancement_output_buffer()` function is hooked to this new action. It starts an output buffer, but only if there are `wp_template_enhancement_output_buffer` filters present, or else if there is an explicit opt-in via the `wp_should_output_buffer_template_for_enhancement` filter.
* The `wp_finalize_template_enhancement_output_buffer()` function serves as the output buffer callback. It applies `wp_template_enhancement_output_buffer` filters to the buffered content if the response is identified as HTML. 
* The output buffer callback passes through (without filtering) any content for non-HTML responses, identified by the `Content-Type` response header.
* This provides a standardized way for plugins (and core) to perform optimizations, such as removing unused CSS, without each opening their own ad hoc output buffer.

Developed in https://github.com/WordPress/wordpress-develop/pull/8412.

Props westonruter, nextendweb, dmsnell, flixos90, jorbin, peterwilsoncc, swissspidy, DrewAPicture, DaanvandenBergh, OptimizingMatters, tabrisrp, jonoaldersonwp, SergeyBiryukov.
Fixes #43258.

Built from https://develop.svn.wordpress.org/trunk@60936


git-svn-id: http://core.svn.wordpress.org/trunk@60272 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2025-10-15 17:14:39 +00:00

58 lines
1.1 KiB
PHP

<?php
/**
* WordPress Version
*
* Contains version information for the current WordPress release.
*
* @package WordPress
* @since 1.2.0
*/
/**
* The WordPress version string.
*
* Holds the current version number for WordPress core. Used to bust caches
* and to enable development mode for scripts when running from the /src directory.
*
* @global string $wp_version
*/
$wp_version = '6.9-alpha-60936';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
*
* @global int $wp_db_version
*/
$wp_db_version = 60717;
/**
* Holds the TinyMCE version.
*
* @global string $tinymce_version
*/
$tinymce_version = '49110-20250317';
/**
* Holds the minimum required PHP version.
*
* @global string $required_php_version
*/
$required_php_version = '7.2.24';
/**
* Holds the names of required PHP extensions.
*
* @global string[] $required_php_extensions
*/
$required_php_extensions = array(
'json',
'hash',
);
/**
* Holds the minimum required MySQL version.
*
* @global string $required_mysql_version
*/
$required_mysql_version = '5.5.5';