MDL-7757 URL check is too restrictive, allow port; backported from HEAD

This commit is contained in:
skodak
2006-12-03 10:24:59 +00:00
parent 5a16abc079
commit b13b2b54a6
+1 -1
View File
@@ -440,7 +440,7 @@ function clean_param($param, $type) {
case PARAM_URL: // allow safe ftp, http, mailto urls
include_once($CFG->dirroot . '/lib/validateurlsyntax.php');
if (!empty($param) && validateUrlSyntax($param, 's?H?S?F?E?u-P-a?I?p-f?q?r?')) {
if (!empty($param) && validateUrlSyntax($param, 's?H?S?F?E?u-P-a?I?p?f?q?r?')) {
// all is ok, param is respected
} else {
$param =''; // not really ok