apply_filters( ‘http_headers_useragent’, string $user_agent, string $url )

In this article

Filters the user agent value sent with an HTTP request.

Parameters

$user_agentstring
WordPress user agent string.
$urlstring
The request URL.

Source

'user-agent'          => apply_filters( 'http_headers_useragent', 'WordPress/' . get_bloginfo( 'version' ) . '; ' . get_bloginfo( 'url' ), $url ),

Changelog

VersionDescription
5.1.0The $url parameter was added.
2.7.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.