- $env{'environment.firstname'}
- $env{'environment.middlename'}
- $env{'environment.lastname'}
- $env{'environment.generation'}
+ $name
@@ -2866,7 +4311,7 @@ $realm
ENDROLE
- my $titleinfo = '
'.$title.' ';
+ my $titleinfo = '
'.$title.' ';
if ($customtitle) {
$titleinfo = $customtitle;
}
@@ -2878,10 +4323,11 @@ ENDROLE
'.domain'}.'/'})) {
my $cid = $env{'request.course.id'};
$dc_info.= $cid.' '.$env{'course.'.$cid.'.internal.coursecode'};
+ $dc_info =~ s/\s+$//;
$dc_info = '('.$dc_info.')';
}
- if ($env{'environment.remote'} eq 'off') {
+ if (($env{'environment.remote'} eq 'off') || ($args->{'suppress_header_logos'})) {
# No Remote
if ($env{'request.state'} eq 'construct') {
$forcereg=1;
@@ -2904,11 +4350,11 @@ ENDROLE
$lastitem = $thisdisfn;
}
$titleinfo =
- &Apache::loncommon::help_open_menu('','','','',3,'Authoring').
- '
Construction Space : '.
- '
'
.&Apache::lonmenu::constspaceform();
@@ -2921,9 +4367,11 @@ ENDROLE
"
$titleinfo $dc_info ".$roleinfo.
'';
}
- if ($notopbar) {
+ if ($no_nav_bar) {
$bodytag .= $titletable;
} else {
+ $bodytag .= qq|
$name ($role)
+ $realm $dc_info
|;
if ($env{'request.state'} eq 'construct') {
$bodytag .= &Apache::lonmenu::menubuttons($forcereg,$forcereg,
$titletable);
@@ -2939,8 +4387,11 @@ ENDROLE
# Top frame rendering, Remote is up
#
- my $upperleft='
';
+ my $imgsrc = $img;
+ if ($img =~ /^\/adm/) {
+ $imgsrc = &lonhttpdurl($img);
+ }
+ my $upperleft='
';
# Explicit link to get inline menu
my $menu= ($no_inline_link?''
@@ -2952,8 +4403,8 @@ ENDROLE
return(<
-$upperleft
- $messages
+$upperleft
+ $messages
$titleinfo $dc_info $menu
$roleinfo
@@ -3023,38 +4474,35 @@ sub make_attr_string {
=pod
-=back
-
-=head1 HTML Helpers
-
-=over 4
-
=item * &endbodytag()
Returns a uniform footer for LON-CAPA web pages.
-Inputs: none
-
-=back
+Inputs: 1 - optional reference to an args hash
+If in the hash, key for noredirectlink has a value which evaluates to true,
+a 'Continue' link is not displayed if the page contains an
+internal redirect in the section,
+i.e., $env{'internal.head.redirect'} exists
=cut
sub endbodytag {
+ my ($args) = @_;
my $endbodytag='';
$endbodytag=&Apache::lontexconvert::jsMath_process()."\n".$endbodytag;
if ( exists( $env{'internal.head.redirect'} ) ) {
- $endbodytag=
- "".
- &mt('Continue').' '.
- $endbodytag;
+ if (!(ref($args) eq 'HASH' && $args->{'noredirectlink'})) {
+ $endbodytag=
+ "".
+ &mt('Continue').' '.
+ $endbodytag;
+ }
}
return $endbodytag;
}
=pod
-=over 4
-
=item * &standard_css()
Returns a style sheet
@@ -3065,8 +4513,6 @@ Inputs: (all optional)
function -> force usage of a specific rolish color scheme
bgcolor -> override the default page bgcolor
-=back
-
=cut
sub standard_css {
@@ -3075,17 +4521,27 @@ sub standard_css {
my $img = &designparm($function.'.img', $domain);
my $tabbg = &designparm($function.'.tabbg', $domain);
my $font = &designparm($function.'.font', $domain);
+ my $fontmenu = &designparm($function.'.fontmenu', $domain);
+#second colour for later usage
my $sidebg = &designparm($function.'.sidebg',$domain);
- my $pgbg = $bgcolor ||
+ my $pgbg_or_bgcolor =
+ $bgcolor ||
&designparm($function.'.pgbg', $domain);
+ my $pgbg = &designparm($function.'.pgbg', $domain);
my $alink = &designparm($function.'.alink', $domain);
my $vlink = &designparm($function.'.vlink', $domain);
my $link = &designparm($function.'.link', $domain);
- my $sans = 'Arial,Helvetica,sans-serif';
+ my $loginbg = &designparm('login.sidebg',$domain);
+ my $bgcol = &designparm('login.bgcol',$domain);
+ my $textcol = &designparm('login.textcol',$domain);
+
+ my $sans = 'Verdana,Arial,Helvetica,sans-serif';
+ my $mono = 'monospace';
my $data_table_head = $tabbg;
my $data_table_light = '#EEEEEE';
- my $data_table_dark = '#DDD';
+ my $data_table_dark = '#DDDDDD';
+ my $data_table_darker = '#CCCCCC';
my $data_table_highlight = '#FFFF00';
my $mail_new = '#FFBB77';
my $mail_new_hover = '#DD9955';
@@ -3095,161 +4551,486 @@ sub standard_css {
my $mail_replied_hover = '#888855';
my $mail_other = '#99BBBB';
my $mail_other_hover = '#669999';
+ my $table_header = '#DDDDDD';
+ my $feedback_link_bg = '#BBBBBB';
+ my $lg_border_color = '#C8C8C8';
+
+ my $border = ($env{'browser.type'} eq 'explorer' ||
+ $env{'browser.type'} eq 'safari' ) ? '0 2px 0 2px'
+ : '0 3px 0 4px';
+
return < td {
+ background-color: #CCCCCC;
+ font-weight: bold;
+ text-align: left;
+}
+
+table.LC_data_table tr.LC_odd_row > td,
+table.LC_pick_box tr > td.LC_odd_row {
background-color: $data_table_light;
+ padding: 2px;
}
-table.LC_data_table tr.LC_even_row td {
+
+table.LC_data_table tr.LC_even_row > td,
+table.LC_pick_box tr > td.LC_even_row {
background-color: $data_table_dark;
+ padding: 2px;
+}
+
+table.LC_data_table tr.LC_data_table_highlight td {
+ background-color: $data_table_darker;
+}
+
+table.LC_data_table tr td.LC_leftcol_header {
+ background-color: $data_table_head;
+ font-weight: bold;
}
-table.LC_data_table tr.LC_empty td {
+
+table.LC_data_table tr.LC_empty_row td,
+table.LC_nested tr.LC_empty_row td {
background-color: #FFFFFF;
+ font-weight: bold;
+ font-style: italic;
+ text-align: center;
+ padding: 8px;
+}
+
+table.LC_nested tr.LC_empty_row td {
+ padding: 4ex
+}
+
+table.LC_nested_outer tr th {
+ font-weight: bold;
+ color:$fontmenu;
+ background-color: $data_table_head;
+ font-size: small;
+ border-bottom: 1px solid #000000;
+}
+
+table.LC_nested_outer tr td.LC_subheader {
+ background-color: $data_table_head;
+ font-weight: bold;
+ font-size: small;
+ border-bottom: 1px solid #000000;
+ text-align: right;
+}
+
+table.LC_nested tr.LC_info_row td {
+ background-color: #CCCCCC;
+ font-weight: bold;
+ font-size: small;
+ text-align: center;
+}
+
+table.LC_nested tr.LC_info_row td.LC_left_item,
+table.LC_nested_outer tr th.LC_left_item {
+ text-align: left;
+}
+
+table.LC_nested td {
+ background-color: #FFFFFF;
+ font-size: small;
+}
+
+table.LC_nested_outer tr th.LC_right_item,
+table.LC_nested tr.LC_info_row td.LC_right_item,
+table.LC_nested tr.LC_odd_row td.LC_right_item,
+table.LC_nested tr td.LC_right_item {
+ text-align: right;
+}
+
+table.LC_nested tr.LC_odd_row td {
+ background-color: #EEEEEE;
+}
+
+table.LC_createuser {
+}
+
+table.LC_createuser tr.LC_section_row td {
+ font-size: small;
+}
+
+table.LC_createuser tr.LC_info_row td {
+ background-color: #CCCCCC;
+ font-weight: bold;
+ text-align: center;
}
table.LC_calendar {
border: 1px solid #000000;
border-collapse: collapse;
}
+
table.LC_calendar_pickdate {
font-size: xx-small;
}
+
table.LC_calendar tr td {
border: 1px solid #000000;
vertical-align: top;
}
+
table.LC_calendar tr td.LC_calendar_day_empty {
background-color: $data_table_dark;
}
+
table.LC_calendar tr td.LC_calendar_day_current {
background-color: $data_table_highlight;
}
@@ -3257,34 +5038,1251 @@ table.LC_calendar tr td.LC_calendar_day_
table.LC_mail_list tr.LC_mail_new {
background-color: $mail_new;
}
+
table.LC_mail_list tr.LC_mail_new:hover {
background-color: $mail_new_hover;
}
+
+table.LC_mail_list tr.LC_mail_even {
+}
+
+table.LC_mail_list tr.LC_mail_odd {
+}
+
table.LC_mail_list tr.LC_mail_read {
background-color: $mail_read;
}
+
table.LC_mail_list tr.LC_mail_read:hover {
background-color: $mail_read_hover;
}
+
table.LC_mail_list tr.LC_mail_replied {
background-color: $mail_replied;
}
+
table.LC_mail_list tr.LC_mail_replied:hover {
background-color: $mail_replied_hover;
}
+
table.LC_mail_list tr.LC_mail_other {
background-color: $mail_other;
}
+
table.LC_mail_list tr.LC_mail_other:hover {
background-color: $mail_other_hover;
}
+
+table.LC_data_table tr > td.LC_browser_file,
+table.LC_data_table tr > td.LC_browser_file_published {
+ background: #CCFF88;
+}
+
+table.LC_data_table tr > td.LC_browser_file_locked,
+table.LC_data_table tr > td.LC_browser_file_unpublished {
+ background: #FFAA99;
+}
+
+table.LC_data_table tr > td.LC_browser_file_obsolete {
+ background: #AAAAAA;
+}
+
+table.LC_data_table tr > td.LC_browser_file_modified,
+table.LC_data_table tr > td.LC_browser_file_metamodified {
+ background: #FFFF77;
+}
+
+table.LC_data_table tr.LC_browser_folder > td {
+ background: #CCCCFF;
+}
+
+table.LC_data_table tr > td.LC_roles_is {
+/* background: #77FF77; */
+}
+
+table.LC_data_table tr > td.LC_roles_future {
+ background: #FFFF77;
+}
+
+table.LC_data_table tr > td.LC_roles_will {
+ background: #FFAA77;
+}
+
+table.LC_data_table tr > td.LC_roles_expired {
+ background: #FF7777;
+}
+
+table.LC_data_table tr > td.LC_roles_will_not {
+ background: #AAFF77;
+}
+
+table.LC_data_table tr > td.LC_roles_selected {
+ background: #11CC55;
+}
+
+span.LC_current_location {
+ font-size:larger;
+ background: $pgbg;
+}
+
+span.LC_parm_menu_item {
+ font-size: larger;
+ font-family: $sans;
+}
+
+span.LC_parm_scope_all {
+ color: red;
+}
+
+span.LC_parm_scope_folder {
+ color: green;
+}
+
+span.LC_parm_scope_resource {
+ color: orange;
+}
+
+span.LC_parm_part {
+ color: blue;
+}
+
+span.LC_parm_folder, span.LC_parm_symb {
+ font-size: x-small;
+ font-family: $mono;
+ color: #AAAAAA;
+}
+
+td.LC_parm_overview_level_menu,
+td.LC_parm_overview_map_menu,
+td.LC_parm_overview_parm_selectors,
+td.LC_parm_overview_restrictions {
+ border: 1px solid black;
+ border-collapse: collapse;
+}
+
+table.LC_parm_overview_restrictions td {
+ border-width: 1px 4px 1px 4px;
+ border-style: solid;
+ border-color: $pgbg;
+ text-align: center;
+}
+
+table.LC_parm_overview_restrictions th {
+ background: $tabbg;
+ border-width: 1px 4px 1px 4px;
+ border-style: solid;
+ border-color: $pgbg;
+}
+
+table#LC_helpmenu {
+ border: none;
+ height: 55px;
+ border-spacing: 0;
+}
+
+table#LC_helpmenu fieldset legend {
+ font-size: larger;
+ font-weight: bold;
+}
+
+table#LC_helpmenu_links {
+ width: 100%;
+ border: 1px solid black;
+ background: $pgbg;
+ padding: 0;
+ border-spacing: 1px;
+}
+
+table#LC_helpmenu_links tr td {
+ padding: 1px;
+ background: $tabbg;
+ text-align: center;
+ font-weight: bold;
+}
+
+table#LC_helpmenu_links a:link,
+table#LC_helpmenu_links a:visited,
+table#LC_helpmenu_links a:active {
+ text-decoration: none;
+ color: $font;
+}
+
+table#LC_helpmenu_links a:hover {
+ text-decoration: underline;
+ color: $vlink;
+}
+
+.LC_chrt_popup_exists {
+ border: 1px solid #339933;
+ margin: -1px;
+}
+
+.LC_chrt_popup_up {
+ border: 1px solid yellow;
+ margin: -1px;
+}
+
+.LC_chrt_popup {
+ border: 1px solid #8888FF;
+ background: #CCCCFF;
+}
+
+table.LC_pick_box {
+ border-collapse: separate;
+ background: white;
+ border: 1px solid black;
+ border-spacing: 1px;
+}
+
+table.LC_pick_box td.LC_pick_box_title {
+ background: $tabbg;
+ font-weight: bold;
+ text-align: right;
+ vertical-align: top;
+ width: 184px;
+ padding: 8px;
+}
+
+table.LC_pick_box td.LC_selfenroll_pick_box_title {
+ background: $tabbg;
+ font-weight: bold;
+ text-align: right;
+ width: 350px;
+ padding: 8px;
+}
+
+table.LC_pick_box td.LC_pick_box_value {
+ text-align: left;
+ padding: 8px;
+}
+
+table.LC_pick_box td.LC_pick_box_select {
+ text-align: left;
+ padding: 8px;
+}
+
+table.LC_pick_box td.LC_pick_box_separator {
+ padding: 0;
+ height: 1px;
+ background: black;
+}
+
+table.LC_pick_box td.LC_pick_box_submit {
+ text-align: right;
+}
+
+table.LC_pick_box td.LC_evenrow_value {
+ text-align: left;
+ padding: 8px;
+ background-color: $data_table_light;
+}
+
+table.LC_pick_box td.LC_oddrow_value {
+ text-align: left;
+ padding: 8px;
+ background-color: $data_table_light;
+}
+
+table.LC_helpform_receipt {
+ width: 620px;
+ border-collapse: separate;
+ background: white;
+ border: 1px solid black;
+ border-spacing: 1px;
+}
+
+table.LC_helpform_receipt td.LC_pick_box_title {
+ background: $tabbg;
+ font-weight: bold;
+ text-align: right;
+ width: 184px;
+ padding: 8px;
+}
+
+table.LC_helpform_receipt td.LC_evenrow_value {
+ text-align: left;
+ padding: 8px;
+ background-color: $data_table_light;
+}
+
+table.LC_helpform_receipt td.LC_oddrow_value {
+ text-align: left;
+ padding: 8px;
+ background-color: $data_table_light;
+}
+
+table.LC_helpform_receipt td.LC_pick_box_separator {
+ padding: 0;
+ height: 1px;
+ background: black;
+}
+
+span.LC_helpform_receipt_cat {
+ font-weight: bold;
+}
+
+table.LC_group_priv_box {
+ background: white;
+ border: 1px solid black;
+ border-spacing: 1px;
+}
+
+table.LC_group_priv_box td.LC_pick_box_title {
+ background: $tabbg;
+ font-weight: bold;
+ text-align: right;
+ width: 184px;
+}
+
+table.LC_group_priv_box td.LC_groups_fixed {
+ background: $data_table_light;
+ text-align: center;
+}
+
+table.LC_group_priv_box td.LC_groups_optional {
+ background: $data_table_dark;
+ text-align: center;
+}
+
+table.LC_group_priv_box td.LC_groups_functionality {
+ background: $data_table_darker;
+ text-align: center;
+ font-weight: bold;
+}
+
+table.LC_group_priv td {
+ text-align: left;
+ padding: 0;
+}
+
+table.LC_notify_front_page {
+ background: white;
+ border: 1px solid black;
+ padding: 8px;
+}
+
+table.LC_notify_front_page td {
+ padding: 8px;
+}
+
+.LC_navbuttons {
+ margin: 2ex 0ex 2ex 0ex;
+}
+
+.LC_topic_bar {
+ font-family: $sans;
+ font-weight: bold;
+ width: 100%;
+ background: $tabbg;
+ vertical-align: middle;
+ margin: 2ex 0ex 2ex 0ex;
+ padding: 3px;
+}
+
+.LC_topic_bar span {
+ vertical-align: middle;
+}
+
+.LC_topic_bar img {
+ vertical-align: bottom;
+}
+
+table.LC_course_group_status {
+ margin: 20px;
+}
+
+table.LC_status_selector td {
+ vertical-align: top;
+ text-align: center;
+ padding: 4px;
+}
+
+div.LC_feedback_link {
+ clear: both;
+ background: white;
+ width: 100%;
+}
+
+span.LC_feedback_link {
+ background: $feedback_link_bg;
+ font-size: larger;
+}
+
+span.LC_message_link {
+ background: $feedback_link_bg;
+ font-size: larger;
+ position: absolute;
+ right: 1em;
+}
+
+table.LC_prior_tries {
+ border: 1px solid #000000;
+ border-collapse: separate;
+ border-spacing: 1px;
+}
+
+table.LC_prior_tries td {
+ padding: 2px;
+}
+
+.LC_answer_correct {
+ background: lightgreen;
+ font-family: $sans;
+ color: darkgreen;
+ padding: 6px;
+}
+
+.LC_answer_charged_try {
+ background: #FFAAAA;
+ font-family: $sans;
+ color: darkred;
+ padding: 6px;
+}
+
+.LC_answer_not_charged_try,
+.LC_answer_no_grade,
+.LC_answer_late {
+ background: lightyellow;
+ font-family: $sans;
+ color: black;
+ padding: 6px;
+}
+
+.LC_answer_previous {
+ background: lightblue;
+ font-family: $sans;
+ color: darkblue;
+ padding: 6px;
+}
+
+.LC_answer_no_message {
+ background: #FFFFFF;
+ font-family: $sans;
+ color: black;
+ padding: 6px;
+}
+
+.LC_answer_unknown {
+ background: orange;
+ font-family: $sans;
+ color: black;
+ padding: 6px;
+}
+
+span.LC_prior_numerical,
+span.LC_prior_string,
+span.LC_prior_custom,
+span.LC_prior_reaction,
+span.LC_prior_math {
+ font-family: monospace;
+ white-space: pre;
+}
+
+span.LC_prior_string {
+ font-family: monospace;
+ white-space: pre;
+}
+
+table.LC_prior_option {
+ width: 100%;
+ border-collapse: collapse;
+}
+
+table.LC_prior_rank,
+table.LC_prior_match {
+ border-collapse: collapse;
+}
+
+table.LC_prior_option tr td,
+table.LC_prior_rank tr td,
+table.LC_prior_match tr td {
+ border: 1px solid #000000;
+}
+
+td.LC_nobreak,
+span.LC_nobreak {
+ white-space: nowrap;
+}
+
+span.LC_cusr_emph {
+ font-style: italic;
+}
+
+span.LC_cusr_subheading {
+ font-weight: normal;
+ font-size: 85%;
+}
+
+table.LC_docs_documents {
+ background: #BBBBBB;
+ border-width: 0;
+ border-collapse: collapse;
+}
+
+table.LC_docs_documents td.LC_docs_document {
+ border: 2px solid black;
+ padding: 4px;
+}
+
+.LC_docs_entry_move {
+ border: none;
+ border-collapse: collapse;
+}
+
+.LC_docs_entry_move td {
+ border: 2px solid #BBBBBB;
+ background: #DDDDDD;
+}
+
+.LC_docs_editor td.LC_docs_entry_commands {
+ background: #DDDDDD;
+ font-size: x-small;
+}
+
+.LC_docs_copy {
+ color: #000099;
+}
+
+.LC_docs_cut {
+ color: #550044;
+}
+
+.LC_docs_rename {
+ color: #009900;
+}
+
+.LC_docs_remove {
+ color: #990000;
+}
+
+.LC_docs_reinit_warn,
+.LC_docs_ext_edit {
+ font-size: x-small;
+}
+
+.LC_docs_editor td.LC_docs_entry_title,
+.LC_docs_editor td.LC_docs_entry_icon {
+ background: #FFFFBB;
+}
+
+.LC_docs_editor td.LC_docs_entry_parameter {
+ background: #BBBBFF;
+ font-size: x-small;
+ white-space: nowrap;
+}
+
+table.LC_docs_adddocs td,
+table.LC_docs_adddocs th {
+ border: 1px solid #BBBBBB;
+ padding: 4px;
+ background: #DDDDDD;
+}
+
+table.LC_sty_begin {
+ background: #BBFFBB;
+}
+
+table.LC_sty_end {
+ background: #FFBBBB;
+}
+
+table.LC_double_column {
+ border-width: 0;
+ border-collapse: collapse;
+ width: 100%;
+ padding: 2px;
+}
+
+table.LC_double_column tr td.LC_left_col {
+ top: 2px;
+ left: 2px;
+ width: 47%;
+ vertical-align: top;
+}
+
+table.LC_double_column tr td.LC_right_col {
+ top: 2px;
+ right: 2px;
+ width: 47%;
+ vertical-align: top;
+}
+
+span.LC_role_level {
+ font-weight: bold;
+}
+
+div.LC_left_float {
+ float: left;
+ padding-right: 5%;
+ padding-bottom: 4px;
+}
+
+div.LC_clear_float_header {
+ padding-bottom: 2px;
+}
+
+div.LC_clear_float_footer {
+ padding-top: 10px;
+ clear: both;
+}
+
+div.LC_grade_show_user {
+ margin-top: 20px;
+ border: 1px solid black;
+}
+
+div.LC_grade_user_name {
+ background: #DDDDEE;
+ border-bottom: 1px solid black;
+ font-weight: bold;
+ font-size: large;
+}
+
+div.LC_grade_show_user_odd_row div.LC_grade_user_name {
+ background: #DDEEDD;
+}
+
+div.LC_grade_show_problem,
+div.LC_grade_submissions,
+div.LC_grade_message_center,
+div.LC_grade_info_links,
+div.LC_grade_assign {
+ margin: 5px;
+ width: 99%;
+ background: #FFFFFF;
+}
+
+div.LC_grade_show_problem_header,
+div.LC_grade_submissions_header,
+div.LC_grade_message_center_header,
+div.LC_grade_assign_header {
+ font-weight: bold;
+ font-size: large;
+}
+
+div.LC_grade_show_problem_problem,
+div.LC_grade_submissions_body,
+div.LC_grade_message_center_body,
+div.LC_grade_assign_body {
+ border: 1px solid black;
+ width: 99%;
+ background: #FFFFFF;
+}
+
+span.LC_grade_check_note {
+ font-weight: normal;
+ font-size: medium;
+ display: inline;
+ position: absolute;
+ right: 1em;
+}
+
+table.LC_scantron_action {
+ width: 100%;
+}
+
+table.LC_scantron_action tr th {
+ font-weight:bold;
+ font-style:normal;
+}
+
+.LC_edit_problem_header,
+div.LC_edit_problem_footer {
+ font-weight: normal;
+ font-size: medium;
+ margin: 2px;
+}
+
+div.LC_edit_problem_header,
+div.LC_edit_problem_header div,
+div.LC_edit_problem_footer,
+div.LC_edit_problem_footer div,
+div.LC_edit_problem_editxml_header,
+div.LC_edit_problem_editxml_header div {
+ margin-top: 5px;
+}
+
+div.LC_edit_problem_header_edit_row {
+ background: $tabbg;
+ padding: 3px;
+ margin-bottom: 5px;
+}
+
+div.LC_edit_problem_header_title {
+ font-weight: bold;
+ font-size: larger;
+ background: $tabbg;
+ padding: 3px;
+}
+
+table.LC_edit_problem_header_title {
+ font-size: larger;
+ font-weight: bold;
+ width: 100%;
+ border-color: $pgbg;
+ border-style: solid;
+ border-width: $border;
+ background: $tabbg;
+ border-collapse: collapse;
+ padding: 0;
+}
+
+div.LC_edit_problem_discards {
+ float: left;
+ padding-bottom: 5px;
+}
+
+div.LC_edit_problem_saves {
+ float: right;
+ padding-bottom: 5px;
+}
+
+hr.LC_edit_problem_divide {
+ clear: both;
+ color: $tabbg;
+ background-color: $tabbg;
+ height: 3px;
+ border: none;
+}
+
+img.stift{
+ border-width: 0;
+ vertical-align: middle;
+}
+
+table#LC_mainmenu{
+ margin-top:10px;
+ width:80%;
+}
+
+table#LC_mainmenu td.LC_mainmenu_col_fieldset{
+ vertical-align: top;
+ width: 45%;
+}
+
+.LC_mainmenu_fieldset_category {
+ color: $font;
+ background: $pgbg;
+ font-family: $sans;
+ font-size: small;
+ font-weight: bold;
+}
+
+div.LC_createcourse {
+ margin: 10px 10px 10px 10px;
+}
+
+/* ---- Remove when done ----
+# The following styles is part of the redesign of LON-CAPA and are
+# subject to change during this project.
+# Don't rely on their current functionality as they might be
+# changed or removed.
+# --------------------------*/
+
+a:hover,
+ol.LC_smallMenu a:hover,
+ol#LC_MenuBreadcrumbs a:hover,
+ol#LC_PathBreadcrumbs a:hover,
+ul#LC_TabMainMenuContent a:hover,
+.LC_FormSectionClearButton input:hover
+ul.LC_TabContent li:hover a {
+ color:#BF2317;
+ text-decoration:none;
+}
+
+h1 {
+ padding: 0;
+ line-height:130%;
+}
+
+h2,h3,h4,h5,h6 {
+ margin: 5px 0 5px 0;
+ padding: 0;
+ line-height:130%;
+}
+
+.LC_hcell {
+ padding:3px 15px 3px 15px;
+ margin: 0;
+ background-color:$tabbg;
+ color:$fontmenu;
+ border-bottom:solid 1px $lg_border_color;
+}
+
+.LC_noBorder {
+ border: 0;
+}
+
+
+/* Main Header with discription of Person, Course, etc. */
+
+.LC_Right {
+ float: right;
+ margin: 0;
+ padding: 0;
+}
+
+.LC_FormSectionClearButton input {
+ background-color:transparent;
+ border: none;
+ cursor:pointer;
+ text-decoration:underline;
+}
+
+.LC_help_open_topic {
+ color: #FFFFFF;
+ background-color: #EEEEFF;
+ margin: 1px;
+ padding: 4px;
+ border: 1px solid #000033;
+ white-space: nowrap;
+/* vertical-align: middle; */
+}
+
+dl,ul,div,fieldset {
+ margin: 10px 10px 10px 0;
+/* overflow: hidden; */
+}
+
+#LC_nav_bar {
+ float: left;
+ margin: 0;
+}
+
+#LC_nav_bar em{
+ font-weight: bold;
+ font-style: normal;
+}
+
+ol.LC_smallMenu {
+ float: right;
+}
+
+ol.LC_smallMenu, ol#LC_PathBreadcrumbs {
+ margin: 0;
+}
+
+ol.LC_smallMenu li {
+ display: inline;
+ padding: 5px 5px 0 10px;
+ vertical-align: top;
+}
+
+ol.LC_smallMenu li img {
+ vertical-align: bottom;
+}
+
+ol.LC_smallMenu a {
+ font-size: 90%;
+ color: RGB(80, 80, 80);
+ text-decoration: none;
+}
+
+ul#LC_TabMainMenuContent {
+ clear: both;
+ color: $fontmenu;
+ background: $tabbg;
+ list-style: none;
+ padding: 0;
+ margin: 0;
+ float:left;
+ width: 100%;
+}
+
+ul#LC_TabMainMenuContent li {
+ float: left;
+ font-weight: bold;
+ line-height: 1.8em;
+ padding: 0 0.8em;
+ border-right: 1px solid black;
+ display: inline;
+ vertical-align: middle;
+}
+
+ul.LC_TabContent ,
+ul.LC_TabContentBigger {
+ display:block;
+ list-style:none;
+ margin: 0;
+ padding: 0;
+}
+
+ul.LC_TabContent li,
+ul.LC_TabContentBigger li {
+ display: inline;
+ border-right: solid 1px $lg_border_color;
+ float:left;
+ line-height:140%;
+ white-space:nowrap;
+}
+
+ul#LC_TabMainMenuContent li a {
+ color: $fontmenu;
+ text-decoration: none;
+}
+
+ul.LC_TabContent {
+ min-height:1.6em;
+}
+
+ul.LC_TabContent li {
+ vertical-align:middle;
+ padding: 0 10px 0 10px;
+ background-color:$tabbg;
+ border-bottom:solid 1px $lg_border_color;
+}
+
+ul.LC_TabContent li a, ul.LC_TabContent li {
+ color:rgb(47,47,47);
+ text-decoration:none;
+ font-size:95%;
+ font-weight:bold;
+ padding-right: 16px;
+}
+
+ul.LC_TabContent li:hover, ul.LC_TabContent li.active {
+ background:#FFFFFF url(/adm/lonIcons/open.gif) no-repeat scroll right center;
+ border-bottom:solid 1px #FFFFFF;
+ padding-right: 16px;
+}
+
+ul.LC_TabContentBigger li {
+ vertical-align:bottom;
+ border-top:solid 1px $lg_border_color;
+ border-left:solid 1px $lg_border_color;
+ padding:5px 10px 5px 10px;
+ margin-left:2px;
+ background:url(/adm/lonIcons/lightGreyBG.png) repeat-x left top;
+}
+
+ul.LC_TabContentBigger li:hover,
+ul.LC_TabContentBigger li.active {
+ background:url(/adm/lonIcons/lightGreyBG.png) repeat-x right bottom;
+}
+
+ul.LC_TabContentBigger li,
+ul.LC_TabContentBigger li a {
+ font-size:110%;
+ font-weight:bold;
+}
+
+ol#LC_MenuBreadcrumbs,
+ol#LC_PathBreadcrumbs,
+ul.LC_CourseBreadcrumbs {
+ border-top: solid 1px RGB(255, 255, 255);
+ height: 20px;
+ line-height: 20px;
+ vertical-align: bottom;
+ margin: 0 0 30px 0;
+ padding-left: 10px;
+ list-style-position: inside;
+ background: url(/adm/lonIcons/lightGreyBG.png) repeat-x left top;
+}
+
+ol#LC_MenuBreadcrumbs li,
+ol#LC_PathBreadcrumbs li,
+ul.LC_CourseBreadcrumbs li {
+/*
+ background: url(/adm/lonIcons/arrow_white.png) no-repeat left center;
+*/
+ display: inline;
+ padding: 0 0 0 10px;
+/* vertical-align: bottom; */
+ overflow:hidden;
+}
+
+ol#LC_MenuBreadcrumbs li a, ul.LC_CourseBreadcrumbs li a {
+ text-decoration: none;
+ font-size:90%;
+}
+
+ol#LC_PathBreadcrumbs li a {
+ text-decoration:none;
+ font-size:100%;
+ font-weight:bold;
+}
+
+.LC_BoxPadding {
+ padding: 10px;
+}
+
+.LC_ContentBoxSpecial {
+ border: solid 1px $lg_border_color;
+}
+
+.LC_ContentBoxSpecialContactInfo {
+ border: solid 1px $lg_border_color;
+ max-width:25%;
+ min-width:25%;
+}
+
+.LC_AboutMe_Image {
+ float:left;
+ margin-right:10px;
+}
+
+.LC_Clear_AboutMe_Image {
+ clear:left;
+}
+
+dl.LC_ListStyleClean dt {
+ padding-right: 5px;
+ display: table-header-group;
+}
+
+dl.LC_ListStyleClean dd {
+ display: table-row;
+}
+
+.LC_ListStyleClean,
+.LC_ListStyleSimple,
+.LC_ListStyleNormal,
+.LC_ListStyle_Border,
+.LC_ListStyleSpecial {
+ /*display:block; */
+ list-style-position: inside;
+ list-style-type: none;
+ overflow: hidden;
+ padding: 0;
+}
+
+.LC_ListStyleSimple li,
+.LC_ListStyleSimple dd,
+.LC_ListStyleNormal li,
+.LC_ListStyleNormal dd,
+.LC_ListStyleSpecial li,
+.LC_ListStyleSpecial dd {
+ margin: 0;
+ padding: 5px 5px 5px 10px;
+ clear: both;
+}
+
+.LC_ListStyleClean li,
+.LC_ListStyleClean dd {
+ padding-top: 0;
+ padding-bottom: 0;
+}
+
+.LC_ListStyleSimple dd,
+.LC_ListStyleSimple li {
+ border-bottom: solid 1px $lg_border_color;
+}
+
+.LC_ListStyleSpecial li,
+.LC_ListStyleSpecial dd {
+ list-style-type: none;
+ background-color: RGB(220, 220, 220);
+ margin-bottom: 4px;
+}
+
+table.LC_SimpleTable {
+ margin:5px;
+ border:solid 1px $lg_border_color;
+}
+
+table.LC_SimpleTable tr {
+ padding: 0;
+ border:solid 1px $lg_border_color;
+}
+
+table.LC_SimpleTable thead {
+ background:rgb(220,220,220);
+}
+
+div.LC_columnSection {
+ display: block;
+ clear: both;
+ overflow: hidden;
+ margin: 0;
+}
+
+div.LC_columnSection>* {
+ float: left;
+ margin: 10px 20px 10px 0;
+ overflow:hidden;
+}
+
+.ContentBoxSpecialTemplate {
+ border: solid 1px $lg_border_color;
+}
+
+.ContentBoxTemplate {
+ padding:10px;
+}
+
+div.LC_columnSection > .ContentBoxTemplate,
+div.LC_columnSection > .ContentBoxSpecialTemplate {
+ width: 600px;
+}
+
+.clear {
+ clear: both;
+ line-height: 0;
+ font-size: 0;
+ height: 0;
+}
+
+.LC_loginpage_container {
+ text-align:left;
+ margin : 0 auto;
+ width:90%;
+ padding: 10px;
+ height: auto;
+ background-color:#FFFFFF;
+ border:1px solid #CCCCCC;
+}
+
+
+.LC_loginpage_loginContainer {
+ float:left;
+ width: 182px;
+ padding: 2px;
+ border:1px solid #CCCCCC;
+ background-color:$loginbg;
+}
+
+.LC_loginpage_loginContainer h2 {
+ margin-top: 0;
+ display:block;
+ background:$bgcol;
+ color:$textcol;
+ padding-left:5px;
+}
+
+.LC_loginpage_loginInfo {
+ float:left;
+ width:182px;
+ border:1px solid #CCCCCC;
+ padding:2px;
+}
+
+.LC_loginpage_space {
+ clear: both;
+ margin-bottom: 20px;
+ border-bottom: 1px solid #CCCCCC;
+}
+
+.LC_loginpage_floatLeft {
+ float: left;
+ width: 200px;
+ margin: 0;
+}
+
+table em {
+ font-weight: bold;
+ font-style: normal;
+}
+
+table.LC_tableBrowseRes,
+table.LC_tableOfContent {
+ border:none;
+ border-spacing: 1;
+ padding: 3px;
+ background-color: #FFFFFF;
+ font-size: 90%;
+}
+
+table.LC_tableOfContent{
+ border-collapse: collapse;
+}
+
+table.LC_tableBrowseRes a,
+table.LC_tableOfContent a {
+ background-color: transparent;
+ text-decoration: none;
+}
+
+table.LC_tableBrowseRes tr.LC_trOdd,
+table.LC_tableOfContent tr.LC_trOdd{
+ background-color: #EEEEEE;
+}
+
+table.LC_tableOfContent img {
+ border: none;
+ height: 1.3em;
+ vertical-align: text-bottom;
+ margin-right: 0.3em;
+}
+
+a#LC_content_toolbar_firsthomework {
+ background-image:url(/res/adm/pages/open-first-problem.gif);
+}
+
+a#LC_content_toolbar_launchnav {
+ background-image:url(/res/adm/pages/start-navigation.gif);
+}
+
+a#LC_content_toolbar_closenav {
+ background-image:url(/res/adm/pages/close-navigation.gif);
+}
+
+a#LC_content_toolbar_everything {
+ background-image:url(/res/adm/pages/show-all.gif);
+}
+
+a#LC_content_toolbar_uncompleted {
+ background-image:url(/res/adm/pages/show-incomplete-problems.gif);
+}
+
+#LC_content_toolbar_clearbubbles {
+ background-image:url(/res/adm/pages/mark-discussionentries-read.gif);
+}
+
+a#LC_content_toolbar_changefolder {
+ background : url(/res/adm/pages/close-all-folders.gif) top center ;
+}
+
+a#LC_content_toolbar_changefolder_toggled {
+ background-image:url(/res/adm/pages/open-all-folders.gif);
+}
+
+ul#LC_toolbar li a:hover {
+ background-position: bottom center;
+}
+
+ul#LC_toolbar {
+ padding: 0;
+ margin: 2px;
+ list-style:none;
+ position:relative;
+ background-color:white;
+}
+
+ul#LC_toolbar li {
+ border:1px solid white;
+ padding: 0;
+ margin: 0;
+ float: left;
+ display:inline;
+ vertical-align:middle;
+}
+
+
+a.LC_toolbarItem {
+ display:block;
+ padding: 0;
+ margin: 0;
+ height: 32px;
+ width: 32px;
+ color:white;
+ border: none;
+ background-repeat:no-repeat;
+ background-color:transparent;
+}
+
+ul.LC_functionslist li {
+ float: left;
+ white-space: nowrap;
+ height: 35px; /* at least as high as heighest list item */
+ margin: 0 15px 15px 10px;
+}
+
+
END
}
=pod
-=over 4
-
=item * &headtag()
Returns a uniform footer for LON-CAPA web pages.
@@ -3294,8 +6292,10 @@ Inputs: $title - optional title for the
$args - optional arguments
force_register - if is true call registerurl so the remote is
informed
- redirect -> array ref of seconds before redirect occurs
- url to redirect to
+ redirect -> array ref of
+ 1- seconds before redirect occurs
+ 2- url to redirect to
+ 3- whether the side effect should occur
(side effect of setting
$env{'internal.head.redirect'} to the url
redirected too)
@@ -3303,8 +6303,8 @@ Inputs: $title - optional title for the
domain
function -> force usage of a specific rolish color scheme
bgcolor -> override the default page bgcolor
-
-=back
+ no_auto_mt_title
+ -> prevent &mt()ing the title arg
=cut
@@ -3315,6 +6315,8 @@ sub headtag {
my $domain = $args->{'domain'} || &determinedomain();
my $bgcolor = $args->{'bgcolor'} || &designparm($function.'.pgbg',$domain);
my $url = join(':',$env{'user.name'},$env{'user.domain'},
+ $Apache::lonnet::perlvar{'lonVersion'},
+ #time(),
$env{'environment.color.timestamp'},
$function,$domain,$bgcolor);
@@ -3322,18 +6324,26 @@ sub headtag {
my $result =
''.
- ' '.
- &font_settings().
- &Apache::lonhtmlcommon::htmlareaheaders();
+ &font_settings();
+ if (!$args->{'frameset'}) {
+ $result .= &Apache::lonhtmlcommon::htmlareaheaders();
+ }
if ($args->{'force_register'}) {
$result .= &Apache::lonmenu::registerurl(1);
}
+ if (!$args->{'no_nav_bar'}
+ && !$args->{'only_body'}
+ && !$args->{'frameset'}) {
+ $result .= &help_menu_js();
+ }
if (ref($args->{'redirect'})) {
- my ($time,$url) = @{$args->{'redirect'}};
+ my ($time,$url,$inhibit_continue) = @{$args->{'redirect'}};
$url = &Apache::lonenc::check_encrypt($url);
- $env{'internal.head.redirect'} = $url;
+ if (!$inhibit_continue) {
+ $env{'internal.head.redirect'} = $url;
+ }
$result.=<
@@ -3342,31 +6352,26 @@ ADDMETA
if (!defined($title)) {
$title = 'The LearningOnline Network with CAPA';
}
-
- $result .= ' LON-CAPA '.&mt($title).' '.$head_extra;
+ if (!$args->{'no_auto_mt_title'}) { $title = &mt($title); }
+ $result .= ' LON-CAPA '.$title.' '
+ .' '
+ .$head_extra;
return $result;
}
=pod
-=over 4
-
=item * &font_settings()
Returns neccessary to set the proper encoding
Inputs: none
-=back
-
=cut
sub font_settings {
my $headerstring='';
- if (($env{'browser.os'} eq 'mac') && (!$env{'browser.mathml'})) {
- $headerstring.=
- ' ';
- } elsif (!$env{'browser.mathml'} && $env{'browser.unicode'}) {
+ if (!$env{'browser.mathml'} && $env{'browser.unicode'}) {
$headerstring.=
' ';
}
@@ -3375,22 +6380,20 @@ sub font_settings {
=pod
-=over 4
-
=item * &xml_begin()
Returns the needed doctype and
Inputs: none
-=back
-
=cut
sub xml_begin {
my $output='';
- &Apache::lonhtmlcommon::init_htmlareafields();
+ if ($env{'internal.start_page'}==1) {
+ &Apache::lonhtmlcommon::init_htmlareafields();
+ }
if ($env{'browser.mathml'}) {
$output=''
@@ -3409,16 +6412,12 @@ sub xml_begin {
=pod
-=over 4
-
=item * &endheadtag()
Returns a uniform for LON-CAPA web pages.
Inputs: none
-=back
-
=cut
sub endheadtag {
@@ -3427,14 +6426,18 @@ sub endheadtag {
=pod
-=over 4
-
=item * &head()
Returns a uniform complete .. section for LON-CAPA web pages.
-Inputs: $title - optional title for the page
- $head_extra - optional extra HTML to put inside the
+Inputs:
+
+=over 4
+
+$title - optional title for the page
+
+$head_extra - optional extra HTML to put inside the
+
=back
=cut
@@ -3446,43 +6449,55 @@ sub head {
=pod
-=over 4
-
=item * &start_page()
Returns a complete .. section for LON-CAPA web pages.
-Inputs: $title - optional title for the page
- $head_extra - optional extra HTML to incude inside the
- $args - additional optional args supported are:
- only_body -> is true will set &bodytag() onlybodytag
+Inputs:
+
+=over 4
+
+$title - optional title for the page
+
+$head_extra - optional extra HTML to incude inside the
+
+$args - additional optional args supported are:
+
+=over 8
+
+ only_body -> is true will set &bodytag() onlybodytag
arg on
- no_nav_bar -> is true will set &bodytag() notopbar arg on
- add_entries -> additional attributes to add to the
- domain -> force to color decorate a page for a
+ no_nav_bar -> is true will set &bodytag() no_nav_bar arg on
+ add_entries -> additional attributes to add to the
+ domain -> force to color decorate a page for a
specific domain
- function -> force usage of a specific rolish color
+ function -> force usage of a specific rolish color
scheme
- redirect -> see &headtag()
- bgcolor -> override the default page bg color
- js_ready -> return a string ready for being used in
+ redirect -> see &headtag()
+ bgcolor -> override the default page bg color
+ js_ready -> return a string ready for being used in
a javascript writeln
- html_encode -> return a string ready for being used in
+ html_encode -> return a string ready for being used in
a html attribute
- force_register -> if is true will turn on the &bodytag()
+ force_register -> if is true will turn on the &bodytag()
$forcereg arg
- body_title -> alternate text to use instead of $title
+ body_title -> alternate text to use instead of $title
in the title box that appears, this text
is not auto translated like the $title is
- frameset -> if true will start with a
+ frameset -> if true will start with a
rather than
- no_title -> if true the title bar won't be shown
- skip_phases -> hash ref of
+ no_title -> if true the title bar won't be shown
+ skip_phases -> hash ref of
head -> skip the generation
body -> skip all generation
-
- no_inline_link -> if true and in remote mode, don't show the
+ no_inline_link -> if true and in remote mode, don't show the
'Switch To Inline Menu' link
+ no_auto_mt_title -> prevent &mt()ing the title arg
+ inherit_jsmath -> when creating popup window in a page,
+ should it have jsmath forced on by the
+ current page
+
+=back
=back
@@ -3493,7 +6508,8 @@ sub start_page {
#&Apache::lonnet::logthis("start_page ".join(':',caller(0)));
my %head_args;
foreach my $arg ('redirect','force_register','domain','function',
- 'bgcolor') {
+ 'bgcolor','frameset','no_nav_bar','only_body',
+ 'no_auto_mt_title') {
if (defined($args->{$arg})) {
$head_args{$arg} = $args->{$arg};
}
@@ -3519,15 +6535,42 @@ sub start_page {
$args->{'only_body'}, $args->{'domain'},
$args->{'force_register'}, $args->{'body_title'},
$args->{'no_nav_bar'}, $args->{'bgcolor'},
- $args->{'no_title'}, $args->{'no_inline_link'});
+ $args->{'no_title'}, $args->{'no_inline_link'},
+ $args);
}
}
if ($args->{'js_ready'}) {
- $result = &js_ready($result);
+ $result = &js_ready($result);
}
if ($args->{'html_encode'}) {
- $result = &html_encode($result);
+ $result = &html_encode($result);
+ }
+
+ # Preparation for new and consistent functionlist at top of screen
+ # if ($args->{'functionlist'}) {
+ # $result .= &build_functionlist();
+ #}
+
+ # Don't add anything more if only_body wanted
+ return $result if $args->{'only_body'};
+
+ #Breadcrumbs
+ if (exists($args->{'bread_crumbs'}) or exists($args->{'bread_crumbs_component'})) {
+ &Apache::lonhtmlcommon::clear_breadcrumbs();
+ #if any br links exists, add them to the breadcrumbs
+ if (exists($args->{'bread_crumbs'}) and ref($args->{'bread_crumbs'}) eq 'ARRAY') {
+ foreach my $crumb (@{$args->{'bread_crumbs'}}){
+ &Apache::lonhtmlcommon::add_breadcrumb($crumb);
+ }
+ }
+
+ #if bread_crumbs_component exists show it as headline else show only the breadcrumbs
+ if(exists($args->{'bread_crumbs_component'})){
+ $result .= &Apache::lonhtmlcommon::breadcrumbs($args->{'bread_crumbs_component'});
+ }else{
+ $result .= &Apache::lonhtmlcommon::breadcrumbs();
+ }
}
return $result;
}
@@ -3535,8 +6578,6 @@ sub start_page {
=pod
-=over 4
-
=item * &head()
Returns a complete section for LON-CAPA web pages.
@@ -3548,7 +6589,11 @@ Inputs: $args - additional optio
a html attribute
frameset -> if true will start with a
rather than
-=back
+ dicsussion -> if true will get discussion from
+ lonxml::xmlend
+ (you can pass the target and parser arguments
+ through optional 'target' and 'parser' args
+ to this routine)
=cut
@@ -3568,7 +6613,7 @@ sub end_page {
if ($args->{'frameset'}) {
$result .= ' ';
} else {
- $result .= &endbodytag();
+ $result .= &endbodytag($args);
}
$result .= "\n";
@@ -3640,32 +6685,98 @@ sub simple_error_page {
}
{
- my $row_count;
+ my @row_count;
sub start_data_table {
- undef($row_count);
- return '';
+ my ($add_class) = @_;
+ my $css_class = (join(' ','LC_data_table',$add_class));
+ unshift(@row_count,0);
+ return ''."\n";
}
sub end_data_table {
- undef($row_count);
- return '
';
+ shift(@row_count);
+ return '
'."\n";;
}
sub start_data_table_row {
- $row_count++;
- return '';
+ my ($add_class) = @_;
+ $row_count[0]++;
+ my $css_class = ($row_count[0] % 2)?'LC_odd_row':'LC_even_row';
+ $css_class = (join(' ',$css_class,$add_class));
+ return ' '."\n";;
+ }
+
+ sub continue_data_table_row {
+ my ($add_class) = @_;
+ my $css_class = ($row_count[0] % 2)?'LC_odd_row':'LC_even_row';
+ $css_class = (join(' ',$css_class,$add_class));
+ return ' '."\n";;
}
sub end_data_table_row {
- return ' ';
+ return ' '."\n";;
+ }
+
+ sub start_data_table_empty_row {
+# $row_count[0]++;
+ return ''."\n";;
+ }
+
+ sub end_data_table_empty_row {
+ return ' '."\n";;
}
sub start_data_table_header_row {
- return '';
+ return ''."\n";;
+ }
+}
+
+=pod
+
+=item * &inhibit_menu_check($arg)
+
+Checks for a inhibitmenu state and generates output to preserve it
+
+Inputs: $arg - can be any of
+ - undef - in which case the return value is a string
+ to add into arguments list of a uri
+ - 'input' - in which case the return value is a HTML
+