--- loncom/interface/loncommon.pm 2009/05/27 18:56:22 1.829 +++ loncom/interface/loncommon.pm 2009/05/30 22:03:32 1.835 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # a pile of common routines # -# $Id: loncommon.pm,v 1.829 2009/05/27 18:56:22 kalberla Exp $ +# $Id: loncommon.pm,v 1.835 2009/05/30 22:03:32 bisitz Exp $ # # Copyright Michigan State University Board of Trustees # @@ -4183,6 +4183,34 @@ sub designparm { ############################################## =pod +=item * &authorspace() + +Inputs: ./. + +Returns: Path to the Construction Space of the current user's + accessed author space + The author space will be that of the current user + when accessing the own author space + and that of the co-author/assistent co-author + when accessing the co-author's/assistent co-author's + space + +=cut + +sub authorspace { + my $caname = ''; + if ($env{'request.role'} =~ /^ca|^aa/) { + (undef,$caname) = + ($env{'request.role'}=~/($match_domain)\/($match_username)$/); + } else { + $caname = $env{'user.name'}; + } + return '/priv/'.$caname.'/'; +} + +############################################## +=pod + =item * &head_subbox() Inputs: $content (contains HTML code with page functions, etc.) @@ -4274,10 +4302,6 @@ Inputs: =item * $forcereg, if page should register as content page (relevant for text interface only) -=item * $customtitle, alternate text to use instead of $title - in the title box that appears, this text - is not auto translated like the $title is - =item * $no_nav_bar, if true, keep the 'what is this' info but remove the navigational links @@ -4302,7 +4326,7 @@ other decorations will be returned. =cut sub bodytag { - my ($title,$function,$addentries,$bodyonly,$domain,$forcereg,$customtitle, + my ($title,$function,$addentries,$bodyonly,$domain,$forcereg, $no_nav_bar,$bgcolor,$no_inline_link,$args)=@_; if (!$args->{'no_auto_mt_title'}) { $title = &mt($title); } @@ -4373,9 +4397,6 @@ $realm  ENDROLE my $titleinfo = '

'.$title.'

'; - if ($customtitle) { - $titleinfo = $customtitle; - } # # Extra info if you are the DC my $dc_info = ''; @@ -4394,7 +4415,7 @@ ENDROLE $forcereg=1; } - if (!$customtitle && $env{'request.state'} eq 'construct') { + if ($env{'request.state'} eq 'construct') { $titleinfo = &CSTR_pageheader(); #FIXME: Will be removed once all scripts have their own calls } @@ -5425,6 +5446,13 @@ div.LC_feedback_link { width: 100%; padding-bottom: 10px; border: 1px $tabbg solid; + height: 22px; + line-height: 22px; + padding-top: 5px; +} + +div.LC_feedback_link img { + height: 22px; } div.LC_feedback_link a{ @@ -5724,12 +5752,6 @@ 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; @@ -5830,6 +5852,10 @@ h2,h3,h4,h5,h6 { border-bottom:solid 1px $lg_border_color; } +.LC_ContentBoxSpecial > .LC_hcell { + margin: 0 -10px 10px -10px; +} + .LC_noBorder { border: 0; } @@ -6015,18 +6041,9 @@ ol#LC_PathBreadcrumbs li a { 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%; + border: solid 1px $lg_border_color; + padding: 0 10px 10px 10px; } .LC_AboutMe_Image { @@ -6115,19 +6132,6 @@ div.LC_columnSection>* { 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; @@ -6494,9 +6498,6 @@ $args - additional optional args support a html attribute force_register -> if is true will turn on the &bodytag() $forcereg arg - 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 rather than skip_phases -> hash ref of @@ -6540,16 +6541,15 @@ sub start_page { my $attr_string = &make_attr_string($args->{'force_register'}, $args->{'add_entries'}); $result .= "\n\n"; - } else { - $result .= - &bodytag($title, - $args->{'function'}, $args->{'add_entries'}, - $args->{'only_body'}, $args->{'domain'}, - $args->{'force_register'}, $args->{'body_title'}, - $args->{'no_nav_bar'}, $args->{'bgcolor'}, - $args->{'no_inline_link'}, - $args); - } + } else { + $result .= + &bodytag($title, + $args->{'function'}, $args->{'add_entries'}, + $args->{'only_body'}, $args->{'domain'}, + $args->{'force_register'}, $args->{'no_nav_bar'}, + $args->{'bgcolor'}, $args->{'no_inline_link'}, + $args); + } } if ($args->{'js_ready'}) {