I am going to use PHP curl to retrieve the web page with custom user-agent, How can I do to pass the custom user-agent?
You can use CURLOPT_USERAGENT to pass custom user-agent via php CURL
$url="http://www.domain.com/api"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL,$url); curl_setopt($ch, CURLOPT_USERAGENT, "custom user-agent"); $exec=curl_exec ($ch);