From 11f1e126e37ab96a35370d1032d11d721e7b8c97 Mon Sep 17 00:00:00 2001 From: samhemelryk Date: Fri, 25 Sep 2009 08:24:50 +0000 Subject: [PATCH] requires-css MDL-16151 Support for css files that use args --- lib/ajax/ajaxlib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ajax/ajaxlib.php b/lib/ajax/ajaxlib.php index 3ed96dc8d9..ea05acfc33 100644 --- a/lib/ajax/ajaxlib.php +++ b/lib/ajax/ajaxlib.php @@ -193,7 +193,7 @@ class page_requirements_manager { throw new coding_exception('Cannot require a CSS file after <head> has been printed.', $stylesheet); } if (!$fullurl) { - if (!file_exists($CFG->dirroot . '/' . $stylesheet)) { + if (!file_exists($CFG->dirroot . '/' . strtok($stylesheet, '?'))) { throw new coding_exception('Attempt to require a CSS file that does not exist.', $stylesheet); } $url = $CFG->httpswwwroot . '/' . $stylesheet; -- 2.39.5