php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #13256 Remote File Size / Attribute
Submitted: 2001-09-11 21:01 UTC Modified: 2001-09-12 01:18 UTC
From: eko at softhome dot net Assigned:
Status: Not a bug Package: Filesystem function related
PHP Version: 4.0.6 OS: Windows & Linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: eko at softhome dot net
New email:
PHP Version: OS:

 

 [2001-09-11 21:01 UTC] eko at softhome dot net
I need to know the file size of remote file, but never be able to do it.

One of the my example PHP Script:

<?php
     $location = "http://www.blockm.com/admin.gif";
     $fp = fopen($location,"w");
     //$fp = file_exists($location);
     if(!$fp) {$message = "File not found";}
     else {$message = "File Found";
           $temp = fstat($location);
           $image = GetImageSize ($location);
     }
     echo "$message<br>";
     echo "File Size: " . $temp[7] . "<br>";
     echo "Image Size: $image[3]<br>";
     fclose($fp);
?>

The above script can working properly for reading local file.

NB: I am doing project for Banner exchange. I want to
put all the banner immage on remote Server. 

Regards
Eko

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-09-12 01:18 UTC] derick@php.net
Ask for support questions on the php-general@lists.php.net mailing list.

Derick
 
PHP Copyright © 2001-2017 The PHP Group
All rights reserved.
Last updated: Sun Nov 19 01:31:42 2017 UTC