Changeset 50391 for trunk/src/wp-includes/https-detection.php
- Timestamp:
- 02/19/2021 09:11:02 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/https-detection.php
r50075 r50391 205 205 // 1. Check if HTML includes the site's Really Simple Discovery link. 206 206 if ( has_action( 'wp_head', 'rsd_link' ) ) { 207 $pattern = esc_url( site_url( 'xmlrpc.php?rsd', 'rpc') ); // See rsd_link().207 $pattern = preg_replace( '#^https?:(?=//)#', '', esc_url( site_url( 'xmlrpc.php?rsd', 'rpc' ) ) ); // See rsd_link(). 208 208 return false !== strpos( $html, $pattern ); 209 209 } … … 219 219 if ( has_action( 'wp_head', 'rest_output_link_wp_head' ) ) { 220 220 // Try both HTTPS and HTTP since the URL depends on context. 221 $pattern = esc_url( preg_replace( '#^https?:(?=//)#', '',get_rest_url() ) ); // See rest_output_link_wp_head().221 $pattern = preg_replace( '#^https?:(?=//)#', '', esc_url( get_rest_url() ) ); // See rest_output_link_wp_head(). 222 222 return false !== strpos( $html, $pattern ); 223 223 }
Note: See TracChangeset
for help on using the changeset viewer.