Menu
Hello,
I’m trying to load an external file so I can copy the contents onto our server. I have something setup like this, but it doesn’t read anything … no errors either.
[CODE]
<?php
$sourceFile = “https://external.domain.com/?id=123¶mter=xyz&ext=.csv”;
$sourceFileHandler = fopen($sourceFile, “r”);
$sourceFileContent = fread($sourceFileHandler,filesize($sourceFile));
echo $sourceFileContent;
?>
If I made the $sourceFile local, it works perfect. Ex:
[CODE]$sourceFile = “file.csv”;
Any ideas?
Thanks.