I am trying to find out file size of an url:
$url1 = \'www.google.com\';
$curl1 = curl_init();
curl_setopt($curl1, CURLOPT_URL, $url1);
curl_setopt($curl1, CURL
curl_setopt($curl1, CURLOPT_FRESH_CONNECT, 1); // don't use a cached version of the url
CURLOPT_FRESH_CONNECT TRUE to force use of a new connection instead of a cached one.
check example here
you can set header
$headers = array(
"Cache-Control: no-cache",
);
curl_setopt($curl1, CURLOPT_HTTPHEADER, $headers);
this link may be helpful to you http://www.php.net/manual/en/function.curl-setopt.php#96903