version 1.1451, 2025/02/07 05:40:54
|
version 1.1455, 2025/02/17 18:30:42
|
Line 1250 END
|
Line 1250 END
|
%select2 = %{$hashref->{$firstdefault}->{'select2'}}; |
%select2 = %{$hashref->{$firstdefault}->{'select2'}}; |
} |
} |
} |
} |
$result .= $middletext; |
|
if ($middletext ne '') { |
if ($middletext ne '') { |
$result .= '<label>'; |
$result .= '<label>'.$middletext; |
} |
} |
$result .= "<select size=\"1\" name=\"$secondselectname\""; |
$result .= "<select size=\"1\" name=\"$secondselectname\""; |
if ($onchangesecond) { |
if ($onchangesecond) { |
Line 3076 sub select_level_form {
|
Line 3075 sub select_level_form {
|
|
|
=pod |
=pod |
|
|
=item * &select_dom_form($defdom,$name,$includeempty,$showdomdesc,$onchange,$incdoms,$excdoms,$disabled) |
=item * &select_dom_form($defdom,$name,$includeempty,$showdomdesc,$onchange,$incdoms,$excdoms,$disabled,$id) |
|
|
Returns a string containing a <select name='$name' size='1'> form to |
Returns a string containing a <select name='$name' size='1'> form to |
allow a user to select the domain to preform an operation in. |
allow a user to select the domain to preform an operation in. |
Line 3095 The optional $excdoms is a reference to
|
Line 3094 The optional $excdoms is a reference to
|
|
|
The optional $disabled argument, if true, adds the disabled attribute to the select tag. |
The optional $disabled argument, if true, adds the disabled attribute to the select tag. |
|
|
|
The option $id argument is the value (if any) to set as the (unique) id attribute for the select tag. |
|
|
=cut |
=cut |
|
|
#------------------------------------------- |
#------------------------------------------- |
sub select_dom_form { |
sub select_dom_form { |
my ($defdom,$name,$includeempty,$showdomdesc,$onchange,$incdoms,$excdoms,$disabled) = @_; |
my ($defdom,$name,$includeempty,$showdomdesc,$onchange,$incdoms,$excdoms,$disabled,$id) = @_; |
if ($onchange) { |
if ($onchange) { |
$onchange = ' onchange="'.$onchange.'"'; |
$onchange = ' onchange="'.$onchange.'"'; |
} |
} |
if ($disabled) { |
if ($disabled) { |
$disabled = ' disabled="disabled"'; |
$disabled = ' disabled="disabled"'; |
} |
} |
|
if ($id ne '') { |
|
$id = ' id="'.$id.'"'; |
|
} |
my (@domains,%exclude); |
my (@domains,%exclude); |
if (ref($incdoms) eq 'ARRAY') { |
if (ref($incdoms) eq 'ARRAY') { |
@domains = sort {lc($a) cmp lc($b)} (@{$incdoms}); |
@domains = sort {lc($a) cmp lc($b)} (@{$incdoms}); |
Line 3116 sub select_dom_form {
|
Line 3120 sub select_dom_form {
|
if (ref($excdoms) eq 'ARRAY') { |
if (ref($excdoms) eq 'ARRAY') { |
map { $exclude{$_} = 1; } @{$excdoms}; |
map { $exclude{$_} = 1; } @{$excdoms}; |
} |
} |
my $selectdomain = "<select name=\"$name\" size=\"1\"$onchange$disabled>\n"; |
my $selectdomain = "<select name=\"$name\" size=\"1\"$onchange$disabled$id>\n"; |
foreach my $dom (@domains) { |
foreach my $dom (@domains) { |
next if ($exclude{$dom}); |
next if ($exclude{$dom}); |
$selectdomain.="<option value=\"$dom\" ". |
$selectdomain.="<option value=\"$dom\" ". |
Line 6943 sub bodytag {
|
Line 6947 sub bodytag {
|
$role = &Apache::lonnet::plaintext($role); |
$role = &Apache::lonnet::plaintext($role); |
} |
} |
|
|
if (!$realm) { $realm=' '; } |
|
|
|
my $extra_body_attr = &make_attr_string($forcereg,\%design); |
my $extra_body_attr = &make_attr_string($forcereg,\%design); |
|
|
# construct main body tag |
# construct main body tag |
Line 6968 sub bodytag {
|
Line 6970 sub bodytag {
|
undef($role); |
undef($role); |
} |
} |
unless ($ltimenu->{'coursetitle'}) { |
unless ($ltimenu->{'coursetitle'}) { |
$realm=' '; |
|
$showcrstitle = 0; |
$showcrstitle = 0; |
} |
} |
} |
} |
Line 6978 sub bodytag {
|
Line 6979 sub bodytag {
|
undef($role); |
undef($role); |
} |
} |
unless ($menuref->{'crs'}) { |
unless ($menuref->{'crs'}) { |
$realm=' '; |
|
$showcrstitle = 0; |
$showcrstitle = 0; |
} |
} |
} |
} |
Line 7046 END
|
Line 7046 END
|
$args->{'links_disabled'}, |
$args->{'links_disabled'}, |
$args->{'links_target'}, |
$args->{'links_target'}, |
$collapsible); |
$collapsible); |
|
my $labeltext = &HTML::Entities::encode(&mt('Primary links')); |
if ($env{'request.noversionuri'} =~ m{^/res/adm/pages/}) { |
if ($env{'request.noversionuri'} =~ m{^/res/adm/pages/}) { |
if ($dc_info) { |
if ($dc_info) { |
$dc_info = qq|<span class="LC_cusr_subheading">$dc_info</span>|; |
$dc_info = qq|<span class="LC_cusr_subheading">$dc_info</span>|; |
} |
} |
$bodytag .= qq|<div id="LC_nav_bar">$left $role<br /> |
$bodytag .= qq|<div id="LC_nav_bar" role="navigation" aria-label="$labeltext">$left $role<br />|; |
<em>$realm</em> $dc_info</div>|; |
unless (($realm eq '') && ($dc_info eq '')) { |
|
$bodytag .= qq|<div id="LC_realm" role="complementary"><em>$realm</em> $dc_info</div>|; |
|
} |
if ($need_endlcint) { |
if ($need_endlcint) { |
$bodytag .= Apache::lonhtmlcommon::scripttag('', 'end'); |
$bodytag .= Apache::lonhtmlcommon::scripttag('', 'end'); |
} |
} |
return $bodytag; |
return $bodytag; |
} |
} |
|
|
|
$bodytag .= '<div class="LC_landmark" role="navigation" aria-label="'.$labeltext.'">'; |
unless ($env{'request.symb'} =~ m/\.page___\d+___/) { |
unless ($env{'request.symb'} =~ m/\.page___\d+___/) { |
$bodytag .= qq|<div id="LC_nav_bar">$left $role</div>|; |
$bodytag .= qq|<div id="LC_nav_bar">$left $role</div>|; |
} |
} |
|
|
$bodytag .= $right; |
$bodytag .= $right.'</div>'; |
|
|
if ($dc_info) { |
if ($dc_info) { |
$dc_info = &dc_courseid_toggle($dc_info); |
$dc_info = &dc_courseid_toggle($dc_info); |
} |
} |
$bodytag .= qq|<div id="LC_realm">$realm $dc_info</div>|; |
unless (($realm eq '') && ($dc_info eq '')) { |
|
$bodytag .= qq|<div id="LC_realm">$realm $dc_info</div>|; |
|
} |
} |
} |
|
|
#if directed to not display the secondary menu, don't. |
#if directed to not display the secondary menu, don't. |
Line 7311 form, .inline {
|
Line 7316 form, .inline {
|
display: inline; |
display: inline; |
} |
} |
|
|
|
.LC_landmark { |
|
margin: 0; |
|
padding: 0; |
|
border: none; |
|
} |
|
|
.LC_visually_hidden:not(:focus):not(:active) { |
.LC_visually_hidden:not(:focus):not(:active) { |
clip-path: inset(50%); |
clip-path: inset(50%); |
height: 1px; |
height: 1px; |
Line 7321 form, .inline {
|
Line 7332 form, .inline {
|
display: inline; |
display: inline; |
} |
} |
|
|
|
.LC_heading_2 { |
|
font-size: 1.17em; |
|
margin-top: 1em; |
|
margin-bottom: 1em; |
|
} |
|
|
.LC_menus_content.shown{ |
.LC_menus_content.shown{ |
display: block; |
display: block; |
} |
} |
Line 8038 table.LC_pick_box {
|
Line 8055 table.LC_pick_box {
|
border-spacing: 1px; |
border-spacing: 1px; |
} |
} |
|
|
table.LC_pick_box td.LC_pick_box_title { |
table.LC_pick_box th.LC_pick_box_title { |
background: $sidebg; |
background: $sidebg; |
font-weight: bold; |
font-weight: bold; |
text-align: left; |
text-align: left; |
Line 9723 OFFLOAD
|
Line 9740 OFFLOAD
|
<meta name="viewport" content="width=device-width, initial-scale=1.0"> |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> |
<meta name="apple-mobile-web-app-capable" content="yes" />'; |
<meta name="apple-mobile-web-app-capable" content="yes" />'; |
} |
} |
$result .= '<meta name="google" content="notranslate" />'."\n"; |
$result .= '<meta name="google" content="notranslate"'; |
|
if (!$args->{'frameset'}) { |
|
$result .= ' /'; |
|
} |
|
$result .= '>'."\n"; |
return $result.'</head>'; |
return $result.'</head>'; |
} |
} |
|
|
Line 19065 sub needs_coursereinit {
|
Line 19086 sub needs_coursereinit {
|
} |
} |
} |
} |
} |
} |
return ($update); |
return ($update); |
} |
} |
return (); |
return (); |
} |
} |
Line 19596 sub create_captcha {
|
Line 19617 sub create_captcha {
|
if (-e $Apache::lonnet::perlvar{'lonCaptchaDir'}.'/'.$md5sum.'.png') { |
if (-e $Apache::lonnet::perlvar{'lonCaptchaDir'}.'/'.$md5sum.'.png') { |
$output = '<input type="hidden" name="crypt" value="'.$md5sum.'" />'."\n". |
$output = '<input type="hidden" name="crypt" value="'.$md5sum.'" />'."\n". |
'<span class="LC_nobreak">'. |
'<span class="LC_nobreak">'. |
&mt('Type in the letters/numbers shown below').' '. |
'<label>'.&mt('Type in the letters/numbers shown below').' '. |
'<input type="text" size="5" name="code" value="" autocomplete="new-password" />'. |
'<input type="text" size="5" name="code" value="" autocomplete="new-password" />'. |
'</span><br />'. |
'</label></span><br />'. |
'<img src="'.$captcha_params{'www_output_dir'}.'/'.$md5sum.'.png" alt="captcha" />'; |
'<img src="'.$captcha_params{'www_output_dir'}.'/'.$md5sum.'.png" alt="captcha" />'; |
last; |
last; |
} |
} |