Created
November 20, 2024 15:59
-
-
Save amboutwe/873f066459f019193044619bbf6dc475 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/********* DO NOT COPY THE PARTS ABOVE THIS LINE *********/ | |
/* Log reason for "could not be resolved" redirect error | |
* Credit: Yoast team | |
* Last Tested: Nov 20 2024 using Yoast SEO 23.9 on WordPress 6.7 | |
*/ | |
function my_log_http_api_debug_event( $response, $context, $class, $parsed_args, $url ){ | |
error_log( "HTTP API Debug: URL: " . $url . " Response: " . print_r( $response, true ) ); | |
} | |
add_action( "http_api_debug", "my_log_http_api_debug_event" , 10, 5 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment