mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 08:56:36 +02:00
Moodle Docs link on home page could be a bit confusing
This commit is contained in:
parent
9bb4d21fa5
commit
9e458bb388
1 changed files with 5 additions and 0 deletions
|
@ -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 = '<a href="' .$CFG->docroot. '/' .$lang. '/' .$path. '">';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue