From 9e458bb3888332de6366c64566fb32495c83b079 Mon Sep 17 00:00:00 2001 From: moodler Date: Sun, 16 Apr 2006 16:21:50 +0000 Subject: [PATCH] Moodle Docs link on home page could be a bit confusing --- lib/weblib.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/weblib.php b/lib/weblib.php index f71ddd4efc..0c4799a338 100644 --- a/lib/weblib.php +++ b/lib/weblib.php @@ -4859,6 +4859,11 @@ function page_doc_link($text='', $iconpath='') { $path = str_replace($CFG->httpswwwroot.'/','', $CFG->pagepath); // Because the page could be HTTPSPAGEREQUIRED $path = str_replace('.php', '', $path); + + if (empty($path)) { // Not for home page + return ''; + } + $lang = str_replace('_utf8', '', current_language()); $str = ''; -- 2.39.5