var self = this;
if (file.size > this.maxbytes) {
- alert("'"+file.name+"' "+M.util.get_string('filetoolarge', 'moodle'));
+ new M.core.alert({message: M.util.get_string('namedfiletoolarge', 'moodle', {filename: file.name})});
return;
}
} else {
// Error - remove the dummy element
resel.parent.removeChild(resel.li);
- alert(result.error);
+ new M.core.alert({message: result.error});
}
}
} else {
- alert(M.util.get_string('servererror', 'moodle'));
+ new M.core.alert({message: M.util.get_string('servererror', 'moodle')});
}
}
};
} else {
// Error - remove the dummy element
resel.parent.removeChild(resel.li);
- alert(result.error);
+ new M.core.alert({message: result.error});
}
}
} else {
- alert(M.util.get_string('servererror', 'moodle'));
+ new M.core.alert({message: M.util.get_string('servererror', 'moodle')});
}
}
};
array('dndworkingtextlink', 'moodle'),
array('dndworkingtext', 'moodle'),
array('dndworkinglink', 'moodle'),
- array('filetoolarge', 'moodle'),
+ array('namedfiletoolarge', 'moodle'),
array('actionchoice', 'moodle'),
array('servererror', 'moodle'),
array('upload', 'moodle'),
tagtype,core_tag
manageofficialtags,core_tag
settypeofficial,core_tag
+filetoolarge,core
$string['file'] = 'File';
$string['fileexists'] = 'There is already a file called {$a}';
$string['filemissing'] = '{$a} is missing';
-$string['filetoolarge'] = 'is too large to upload';
$string['files'] = 'Files';
$string['filesanduploads'] = 'Files and uploads';
$string['filesfolders'] = 'Files/folders';
$string['mymoodledashboard'] = 'My Moodle dashboard';
$string['myprofile'] = 'My profile';
$string['name'] = 'Name';
+$string['namedfiletoolarge'] = 'The file \'{$a->filename}\' is too large and cannot be uploaded';
$string['nameforlink'] = 'What do you want to call this link?';
$string['nameforpage'] = 'Name';
$string['navigation'] = 'Navigation';
$string['yourteacher'] = 'your {$a}';
$string['yourwordforx'] = 'Your word for \'{$a}\'';
$string['zippingbackup'] = 'Zipping backup';
+
+// Deprecated since Moodle 3.1.
+$string['filetoolarge'] = 'is too large to upload';