mirror of
https://github.com/moodle/moodle.git
synced 2025-03-14 04:30:15 +01:00
Merge branch 'MDL-29619-master' of git://github.com/ankitagarwal/moodle
This commit is contained in:
commit
5117a3d789
@ -44,6 +44,7 @@ $string['displayselect_help'] = 'This setting, together with the URL file type a
|
||||
$string['displayselectexplain'] = 'Choose display type, unfortunately not all types are suitable for all URLs.';
|
||||
$string['externalurl'] = 'External URL';
|
||||
$string['framesize'] = 'Frame height';
|
||||
$string['invalidstoredurl'] = 'Invalid URL';
|
||||
$string['chooseavariable'] = 'Choose a variable...';
|
||||
$string['invalidurl'] = 'Entered URL is invalid';
|
||||
$string['modulename'] = 'URL';
|
||||
|
@ -55,6 +55,12 @@ $completion->set_module_viewed($cm);
|
||||
|
||||
$PAGE->set_url('/mod/url/view.php', array('id' => $cm->id));
|
||||
|
||||
// Make sure URL is valid before generating output
|
||||
$url->externalurl = clean_param($url->externalurl, PARAM_URL);
|
||||
if (empty($url->externalurl)) {
|
||||
print_error('invalidstoredurl', 'url');
|
||||
}
|
||||
|
||||
if ($redirect) {
|
||||
// coming from course page or url index page,
|
||||
// the redirection is needed for completion tracking and logging
|
||||
|
Loading…
x
Reference in New Issue
Block a user