--- loncom/interface/loncommon.pm 2007/08/11 15:18:24 1.561 +++ loncom/interface/loncommon.pm 2007/08/15 16:25:14 1.563 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # a pile of common routines # -# $Id: loncommon.pm,v 1.561 2007/08/11 15:18:24 www Exp $ +# $Id: loncommon.pm,v 1.563 2007/08/15 16:25:14 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1424,7 +1424,7 @@ sub select_level_form { =pod -=item * select_dom_form($defdom,$name,$includeempty) +=item * select_dom_form($defdom,$name,$includeempty,$showdomdesc) Returns a string containing a \n"; foreach my $dom (@domains) { $selectdomain.="\n"; + ($dom eq $defdom ? 'selected="selected" ' : '').'>'.$dom; + if ($showdomdesc) { + if ($dom ne '') { + my $domdesc = &Apache::lonnet::domain($dom,'description'); + if ($domdesc ne '') { + $selectdomain .= ' ('.$domdesc.')'; + } + } + } + $selectdomain .= "\n"; } $selectdomain.=""; return $selectdomain; @@ -3397,6 +3407,9 @@ Inputs: =item * $args, optional argument valid values are no_auto_mt_title -> prevents &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 @@ -3453,7 +3466,7 @@ sub bodytag { # construct main body tag my $bodytag = "". - &Apache::lontexconvert::init_math_support(); + &Apache::lontexconvert::init_math_support($args->{'inherit_jsmath'}); if ($bodyonly) { return $bodytag; @@ -4711,6 +4724,10 @@ Inputs: $title - optional title for the 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 + =cut sub start_page { @@ -5558,9 +5575,8 @@ sub user_picker { $srchterm = $srch->{'srchterm'}; } my %lt=&Apache::lonlocal::texthash( - 'usr' => 'Search for', - 'or' => 'or', - 'doma' => 'domain', + 'usr' => 'Search criteria', + 'doma' => 'Domain/institution to search', 'uname' => 'username', 'lastname' => 'last name', 'lastfirst' => 'last name, first name', @@ -5571,9 +5587,8 @@ sub user_picker { 'exact' => 'is', 'contains' => 'contains', ); - my $domform = &select_dom_form($currdom,'srchdomain',1); - - my $srchin; + my $domform = &select_dom_form($currdom,'srchdomain',1,1); + my $srchinsel = ' $lt{$option} $extra - - -ROW + if ($curr_selected{'srchin'} eq $option) { + $srchinsel .= ' + '; + } else { + $srchinsel .= ' + '; + } } + $srchinsel .= "\n \n"; my $srchbysel = ' + $lt{'usr'}: + $srchbysel + $srchtypesel + +   $srchinsel + + + + $lt{'doma'}: + $domform -$srchin
END_BLOCK