0

Is it possible to get the remote file size for a list of links, get the file size for each and every one of these links from a array or .txt file?

1 Answers1

1

hope that below will fit your needs

function remote_file_size($url){

$header = get_headers($url, true);

if (isset($header['Content-Length']))

    return (int) $header['Content-Length'];
}
Saddam Abu Ghaida
  • 6,381
  • 2
  • 22
  • 29