--- loncom/interface/lonaboutme.pm 2005/11/18 13:35:30 1.39 +++ loncom/interface/lonaboutme.pm 2006/04/08 06:59:34 1.41 @@ -1,7 +1,7 @@ # The LearningOnline Network # "About Me" Personal Information # -# $Id: lonaboutme.pm,v 1.39 2005/11/18 13:35:30 www Exp $ +# $Id: lonaboutme.pm,v 1.41 2006/04/08 06:59:34 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -36,6 +36,7 @@ use Apache::lontexconvert; use Apache::lonfeedback; use Apache::lonrss(); use Apache::lonlocal; +use Apache::lonmsgdisplay(); sub handler { my $r = shift; @@ -44,21 +45,14 @@ sub handler { return OK if $r->header_only; my $target=$env{'form.grade_target'}; # ------------------------------------------------------------ Print the screen - if ($target ne 'tex') { - my $html=&Apache::lonxml::xmlbegin(); - $r->print(< -The LearningOnline Network with CAPA -ENDDOCUMENT - } else { + if ($target eq 'tex') { $r->print(&Apache::lonprintout::print_latex_header($env{'form.latex_type'})); } my (undef,undef,$cdom,$cnum)=split(/\//,$r->uri); # Is this even a user? if (&Apache::lonnet::homeserver($cnum,$cdom) eq 'no_host') { - $r->print(''. - &mt('No user information available').''); + &Apache::loncommon::simple_error_page($r,'No info', + 'No user information available'); return OK; } # --------------------------------------------------------- The syllabus fields @@ -84,9 +78,14 @@ ENDDOCUMENT # --------------------------------------- There is such a user, get environment my %courseenv=&Apache::lonnet::dump('environment',$cdom,$cnum); if ($target ne 'tex') { - $r->print(''.&Apache::loncommon::bodytag - ("Personal Information",$forcestudent,$addentries,'',$cdom, - $env{'form.register'})); + my $start_page = + &Apache::loncommon::start_page("Personal Information",undef, + {'function' => $forcestudent, + 'add_entries' => $addentries, + 'domain' => $cdom, + 'force_register' => + $env{'form.register'},}); + $r->print($start_page); $r->print('

'.&Apache::loncommon::plainname($cnum,$cdom).'

'); } else { $r->print('\noindent{\large\textbf{'.&Apache::loncommon::plainname($cnum,$cdom).'}}\\\\\\\\'); @@ -220,7 +219,7 @@ ENDDOCUMENT &mt('Shared by course faculty and staff'). &Apache::loncommon::help_open_topic("Course_Face_To_Face_Records,Course_Critical_Message"). '
'); - &Apache::lonmsg::disfacetoface($r,$cnum,$cdom); + &Apache::lonmsgdisplay::disfacetoface($r,$cnum,$cdom); $r->print('
'); if (&Apache::lonnet::allowed('vsa', $env{'request.course.id'}) || @@ -234,11 +233,15 @@ ENDDOCUMENT $r->print(&Apache::loncommon::noteswrapper('Add Records',$cnum,$cdom)); } else { $r->print('\\\\\textbf{'.&mt('User Notes, Records of Face-To-Face Discussions, and Critical Messages in Course').'}\\\\'.&mt('Shared by course faculty and staff').'\\\\\\\\'); - &Apache::lonmsg::disfacetoface($r,$cnum,$cdom); + &Apache::lonmsgdisplay::disfacetoface($r,$cnum,$cdom); } } } - if ($target ne 'tex') {$r->print('');} else {$r->print('\end{document}');} + if ($target ne 'tex') { + $r->print(&Apache::loncommon::end_page()); + } else { + $r->print('\end{document}'); + } return OK; }