mirror of
https://github.com/icecoder/ICEcoder.git
synced 2026-03-03 07:13:59 +01:00
Extra fallback to open file
This commit is contained in:
@@ -74,7 +74,9 @@ function getData($url,$type='fopen',$dieMessage=false,$timeout=60) {
|
||||
if (!$data) {
|
||||
$data = @file_get_contents(str_replace("https:","http:",$url), false, $context);
|
||||
}
|
||||
}
|
||||
} elseif (file_exists($url)) {
|
||||
$data = file_get_contents($url);
|
||||
}
|
||||
// Return data or die with message
|
||||
if ($data) {
|
||||
return $data;
|
||||
@@ -298,4 +300,4 @@ function getVersionsCount($fileLoc,$fileName) {
|
||||
"dateCounts" => $dateCounts
|
||||
);
|
||||
}
|
||||
?>
|
||||
?>
|
||||
|
||||
Reference in New Issue
Block a user