mirror of
https://github.com/moodle/moodle.git
synced 2025-03-14 12:40:01 +01:00
Merged helplink fix from stable
This commit is contained in:
parent
c96a3047ec
commit
a6320cc0b8
@ -4142,12 +4142,13 @@ function helpbutton ($page, $title='', $module='moodle', $image=true, $linktext=
|
||||
$module = 'moodle';
|
||||
}
|
||||
|
||||
$linkobject = '<span class="helplink">';
|
||||
|
||||
//Accessibility: prefix the alt text/title with 'Help with', strip distracting dots '...'
|
||||
// PLEASE DO NOT CHANGE. ('...' is VERY distracting for non-visual users)
|
||||
$tooltip = get_string('helpprefix', '', trim($title, ". \t"));
|
||||
|
||||
$linkobject = '';
|
||||
|
||||
if ($image) {
|
||||
if ($imagetext == '') {
|
||||
$imagetext = '<img alt="'.$tooltip.'" src="'.
|
||||
@ -4163,15 +4164,15 @@ function helpbutton ($page, $title='', $module='moodle', $image=true, $linktext=
|
||||
$linkobject .= $tooltip;
|
||||
}
|
||||
|
||||
$linkobject .= '</span>';
|
||||
|
||||
if ($text) {
|
||||
$url = '/help.php?module='. $module .'&text='. s(urlencode($text));
|
||||
} else {
|
||||
$url = '/help.php?module='. $module .'&file='. $page .'.html';
|
||||
}
|
||||
|
||||
$link = link_to_popup_window ($url, 'popup', $linkobject, 400, 500, $tooltip, 'none', true);
|
||||
$link = '<span class="helplink">'.
|
||||
link_to_popup_window ($url, 'popup', $linkobject, 400, 500, $tooltip, 'none', true).
|
||||
'</span>';
|
||||
|
||||
if ($return) {
|
||||
return $link;
|
||||
|
Loading…
x
Reference in New Issue
Block a user