Remote file

I have content that I moved from a remote server and renamed making a new file date. I want to provide the original creation date of the remote file in a form. I was able to use filectime without issue for local files but don’t know how to access the remote data. I don’t have access to the php.ini file and from reading, this may be my issue. I wouldn’t think I have to fopen a file to get its directory listing data. Am I missing something?

<?php //test remote date $pdate = "not found"; $fname="https://remote.com/fileIamlookingfor.pdf"; if (file_exists($new)){ $pdate = date('m-d-y',filectime($fname)); } echo $new . " created: " . $pdate; ?>
<?php 
//test remote date 
$pdate = "not found"; $fname="https://remote.com/fileIamlookingfor.pdf";
 if (file_exists($new)){
       $pdate = date('m-d-y',filectime($fname)); 
} 
echo $new . " created: " . $pdate; 
?>

Sponsor our Newsletter | Privacy Policy | Terms of Service