mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
Adding workaround for PHP < 4.3.0 where file_get_contents does not exist.
This commit is contained in:
parent
a43b5308c8
commit
7ab8bb7160
@ -96,4 +96,11 @@ function put_records_csv($file, $records, $table = NULL) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (!function_exists('file_get_contents')) {
|
||||
function file_get_contents($file) {
|
||||
$file = file($file);
|
||||
return !$file ? false : implode('', $file);
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
|
Loading…
x
Reference in New Issue
Block a user