From 016bfc83bc8530c233f2415b5c72326782d5897e Mon Sep 17 00:00:00 2001 From: moodler Date: Fri, 13 Feb 2004 08:34:39 +0000 Subject: [PATCH] A new is_windows function --- lib/moodlelib.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/moodlelib.php b/lib/moodlelib.php index 398df3d31b..c20f6346c9 100644 --- a/lib/moodlelib.php +++ b/lib/moodlelib.php @@ -1993,6 +1993,12 @@ function check_browser_version($brand="MSIE", $version=5.5) { return false; } +function is_windows() { +/// Detects whether the server is Windows + global $CFG; + + return strpos($CFG->dirroot, ':'); +} function ini_get_bool($ini_get_arg) { /// This function makes the return value of ini_get consistent if you are -- 2.39.5