Log HTTP Requests

Descripción

Registra y ve todas las peticiones HTTP de WP

¡Cuánto tardan en ejecutarse las comprobaciones de actualización de [núcleo/ plugins / temas]? ¿Qué datos de mi sitio se están enviado? ¿Qué pasa con todas esas peticiones ajax? Las respuestas a estas preguntas están a solo unos pocos clics de distancia.

Este plugin registra todas las peticiones de WP_HTTP y las muestra en un listado de tabla para una fácil visualización. También almacena el tiempo de ejecución de cada petición HTTP.

Ganchos disponibles

Personaliza la duración (en días) antes de que se eliminen los elementos del registro anteriores:

add_filter( 'lhr_expiration_days', function( $days ) {
    return 7; // default = 1
});

No registrar elementos de un hostname específico:

add_filter( 'lhr_log_data', function( $data ) {
    if ( false !== strpos( $data['url'], 'wordpress.org' ) ) {
        return false;
    }
    return $data;
});

En el ejemplo de arriba las claves del array $data corresponden a columnasa dentro de la tabla lhr_log de la base de datos.

Enlaces importantes

Instalación

  1. Descarga y activa el plugin.
  2. Ve a Herramientas > Registro de peticiones HTTP para ver las entradas del registro.

Reseñas

22 de septiembre de 2021
This plugin is so helpful for tracking down whether an HTTP request was made at all, and when it was, what data was sent and what response was received. It's invaluable for tracking down bugs tied to unexpected responses and requests.
6 de diciembre de 2020
The Log HTTP Requests plugin might be my favorite troubleshooting tool of all time. It's helped me pinpoint intermittent issues that we never would have seen otherwise. THANK YOU, FacetWP! 🙂
22 de octubre de 2020
After installing this plugin I noticed a lot of requests being made to one site. It turns out that there was a bug in the caching of the request data, and it was being made on every page load. Fixing this has given a big performance improvement. Thank you.
28 de octubre de 2019
I was looking for a way to look at client's json requests and responses, I was always stuck at "well, I have to be at my client's side at exactly the moment the error occurs, and while I'm also looking at the network tab at the browser". Not anymore! Thanks man, really appreciate this! One point if I may suggest, add a filtering to the log. Either only log URL which contain a "certain phrase", OR log everything and then add a search feature. Either of those would be perfect.
12 de septiembre de 2019
This plugin has become indispensable for plugin development particularly debugging API requests. Thank you very much.
Leer todas las 11 reseñas

Colaboradores y desarrolladores

«Log HTTP Requests» es un software de código abierto. Las siguientes personas han colaborado con este plugin.

Colaboradores

«Log HTTP Requests» ha sido traducido a 1 idioma local. Gracias a los traductores por sus contribuciones.

Traduce «Log HTTP Requests» a tu idioma.

¿Interesado en el desarrollo?

Revisa el código , echa un vistazo al repositorio SVN o suscríbete al registro de desarrollo por RSS.

Registro de cambios

= 1.4.1
* Fixed PHP8 deprecation notices

1.4

  • Añadida validación de perfil ajax adicional (gracias a pluginvulnerabilities.com)

1.3.2

  • Escaped URL field to prevent possible XSS (props Bishop Fox)

1.3.1

  • Ensured compatibility with WP 5.8

1.3

  • Minor PHP cleanup
  • Ensured compatibility with WP 5.7

1.2

  • Moved «Log HTTP Requests» to the Tools menu (props @aaemnnosttv)
  • Added «Status» column to show HTTP response code (props @danielbachhuber)
  • Added prev/next browsing to the detail modal (props @marcissimus)
  • Added keyboard support (up, down, esc) to the detail modal (props @marcissimus)
  • Added raw timestamp to «Date Added» column on hover
  • Added hook docs to the readme

1.1

  • Added lhr_log_data hook to customize logged data (return FALSE to skip logging)
  • Added lhr_expiration_days hook

1.0.4

  • Minor styling tweak

1.0.3

  • Better visibility for long URLs

1.0.2

  • Minor design tweaks
  • Replaced json_encode with wp_send_json

1.0.1

  • Tested compatibility against WP 4.9.4

1.0.0

  • Initial release