General: Improve MS Edge user-agent sniff.
Update the `$is_edge` global to be `true` if the browser's user-agent contains `Edg` rather than `Edge`. Microsoft have dropped an E from the UA string. Refer to [https://docs.microsoft.com/en-us/microsoft-edge/web-platform/user-agent-guidance#identifiers-for-microsoft-edge-on-various-platforms Microsoft's documentation on detecting edge]. Props costdev, abdullahramzan, mukesh27, Boniu91. Fixes #55297. Built from https://develop.svn.wordpress.org/trunk@52825 git-svn-id: http://core.svn.wordpress.org/trunk@52414 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
c274ea83f3
commit
f3d929163f
|
@ -65,7 +65,7 @@ $is_edge = false;
|
|||
if ( isset( $_SERVER['HTTP_USER_AGENT'] ) ) {
|
||||
if ( strpos( $_SERVER['HTTP_USER_AGENT'], 'Lynx' ) !== false ) {
|
||||
$is_lynx = true;
|
||||
} elseif ( strpos( $_SERVER['HTTP_USER_AGENT'], 'Edge' ) !== false ) {
|
||||
} elseif ( strpos( $_SERVER['HTTP_USER_AGENT'], 'Edg' ) !== false ) {
|
||||
$is_edge = true;
|
||||
} elseif ( stripos( $_SERVER['HTTP_USER_AGENT'], 'chrome' ) !== false ) {
|
||||
if ( stripos( $_SERVER['HTTP_USER_AGENT'], 'chromeframe' ) !== false ) {
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '6.0-alpha-52824';
|
||||
$wp_version = '6.0-alpha-52825';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue