wpseek.com
Outil de recherche WordPress pour les développeurs et auteurs de thèmes



wp_is_document_isolation_policy_supported › WordPress Function

Depuis7.2.0
Dépréciéen/a
› wp_is_document_isolation_policy_supported ( Pas de paramètres )
Retourne:
  • (bool) True when the browser is Chromium 137 or newer.
Défini(e) dans:
Codex:

Determines whether the current request's browser honors the Document-Isolation-Policy header.

Document-Isolation-Policy is how WordPress makes a page cross-origin isolated for client-side media processing. Chromium 137+ is the only engine that implements it; other browsers ignore the header, so the page never becomes isolated and the client-side pipeline cannot run.


Source

function wp_is_document_isolation_policy_supported(): bool {
	$chromium_version = wp_get_chromium_major_version();

	return null !== $chromium_version && $chromium_version >= 137;
}