OK a number of small changes here.

Firstly, I'm replacing all use of old-style global variables like
$HTTY_REFERER with their new-style equivalent $_SERVER["HTTP_REFERER"]
Also using $_POST instead $HTTP_POST_VARS  etc

Secondly, if gdversion == 0 (ie GD is not installed) then:

 - users are not even allowed to upload new images
 - graphs now just print a message instead of failing.

this allows Moodle to still be used even if GD is not present
This commit is contained in:
moodler
2003-01-05 06:45:20 +00:00
parent 3b7c1de95e
commit 607809b3ba
25 changed files with 147 additions and 95 deletions
+2 -2
View File
@@ -130,8 +130,8 @@
} else if ($mode == "compare") {
if (isset($HTTP_POST_VARS['file'])){ // Save a file
$newstrings = $HTTP_POST_VARS;
if (isset($_POST['file'])){ // Save a file
$newstrings = $_POST;
$file = $newstrings['file'];
unset($newstrings['file']);
if (lang_save_file($langdir, $file, $newstrings)) {