I have the code to get the size of the webpage.
Problem with this code is, it is not returning the page size if the site have HTTPS
How to get the total size of the URL or webpage in php
$url = 'facebook.com';
$curl = curl_init($url);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);
$subject = curl_exec($curl);
print("Download size: " . curl_getinfo($curl, CURLINFO_SIZE_DOWNLOAD) .'<br>');
Aucun commentaire:
Enregistrer un commentaire