Diff for /loncom/interface/lonhelpmenu.pm between versions 1.9 and 1.46

version 1.9, 2004/07/13 17:35:58 version 1.46, 2018/05/08 01:19:06
Line 1 Line 1
 # The LearningOnline Network with CAPA  # The LearningOnline Network with CAPA
 # generate frame-based help system  # generate frame-based help system
 #  #
   # $Id$
   #
 # Copyright Michigan State University Board of Trustees  # Copyright Michigan State University Board of Trustees
 #  #
 # This file is part of the LearningOnline Network with CAPA (LON-CAPA).  # This file is part of the LearningOnline Network with CAPA (LON-CAPA).
Line 30  use strict; Line 32  use strict;
 use lib qw(/home/httpd/lib/perl);  use lib qw(/home/httpd/lib/perl);
 use Apache::Constants qw(:common);  use Apache::Constants qw(:common);
 use Apache::loncommon();  use Apache::loncommon();
   use Apache::lonlocal;
   use Apache::lonnet;
   use lib '/home/httpd/lib/perl/';
   use LONCAPA;
   use HTML::Entities();
   
 sub handler {  sub handler {
     my ($r) = @_;      my ($r) = @_;
     &Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'},['page','color','function','faq','bug','topic','component_help','origurl','stayonpage']);      &Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'},['page','faq','bug','topic','component_help','origurl','stayonpage']);
     &Apache::loncommon::content_type($r,'text/html');      &Apache::loncommon::content_type($r,'text/html');
     $r->send_http_header;      $r->send_http_header;
   
     if ($r->header_only) {      if ($r->header_only) {
         return OK;          return OK;
     }      }
     my $color = $ENV{'form.color'};      my $faq = $env{'form.faq'};
     my $faq = $ENV{'form.faq'};      my $bug = $env{'form.bug'};
     my $bug = $ENV{'form.bug'};      my $topic = $env{'form.topic'};
     my $topic = $ENV{'form.topic'};      my $component_help = $env{'form.component_help'};
     my $function = $ENV{'form.function'};      my $origurl = $env{'form.origurl'};
     my $component_help = $ENV{'form.component_help'};      my $stayOnPage = $env{'form.stayonpage'};
     my $origurl = $ENV{'form.origurl'};  
     my $stayOnPage = $ENV{'form.stayonpage'};  
     my $component_url = $component_help;      my $component_url = $component_help;
     if ($component_url) {      if ($component_url) {
         $component_url = '/adm/help/'.$component_url.'.hlp';          $component_url = '/adm/help/'.$component_url.'.hlp';
     }      }
     my $bugurl = $Apache::lonnet::perlvar{'BugzillaHost'};      my $bugurl = $Apache::lonnet::perlvar{'BugzillaHost'};
     $bugurl .= 'enter_bug.cgi?product=LON-CAPA&bug_file_loc='.$origurl;      $bugurl .= 'enter_bug.cgi?product=LON-CAPA&bug_file_loc='.$origurl;
     if ($bug) {      if ($bug) {
         $bugurl .= '&component='.$bug;          $bugurl .= '&component='.$bug;
     }      }
     my $faqbaseurl = $Apache::lonnet::perlvar{'FAQHost'};      my $faqbaseurl = $Apache::lonnet::perlvar{'FAQHost'};
     my $requestmail = $Apache::lonnet::perlvar{'lonSupportEMail'};      my $origmail = $Apache::lonnet::perlvar{'lonSupportEMail'};
     if ($ENV{'form.page'} eq 'banner') {      $origurl = &unescape($origurl);
         &display_help_banner($r,$color,$function,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail,$stayOnPage);      my $defdom;
     } elsif ($ENV{'form.page'} eq 'body') {      if ($env{'request.course.id'}) {
         &display_help_mainpage($r,$color,$function,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail);          $defdom = $env{'course.'.$env{'request.course.id'}.'.domain'};
       } elsif ($env{'request.role.domain'}) {
           $defdom = $env{'request.role.domain'};
       } else {
           $defdom = &Apache::lonnet::default_login_domain();
       }
       my $requestmail = &Apache::loncommon::build_recipient_list(undef,'helpdeskmail',
                                                                  $defdom,$origmail);
       if ($env{'form.page'} eq 'banner') {
           &display_help_banner($r,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail,$stayOnPage);
       } elsif ($env{'form.page'} eq 'body') {
           &display_help_mainpage($r,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail,$stayOnPage);
     }      }
     return OK;      return OK;
 }  }
   
 sub display_help_banner {  sub display_help_banner {
     my ($r,$color,$function,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail,$stayOnPage) = @_;      my ($r,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail,$stayOnPage) = @_;
     my $bodytag = &Apache::loncommon::bodytag('',$function,'rightmargin="0" leftmargin="0" marginwidth="0" topmargin="1" marginheight="1"',1);      my $dom = $env{'request.role.domain'};
     $bodytag=~s/[\n\r]/ /g;      my $scripttag = '';
     my $fontcolor = &Apache::loncommon::designparm($function.'.font');      if ($requestmail) {
     my $alinkcolor = &Apache::loncommon::designparm($function.'.alink');          my $displayurl = &escape($origurl);
     my $vlinkcolor = &Apache::loncommon::designparm($function.'.vlink');          $scripttag = (<<"SCRIPT_ONE");
     my $pagecolor = &Apache::loncommon::designparm($function.'.pgbg');  <script type="text/javascript">
     my $tablecolor = &Apache::loncommon::designparm($function.'.tabbg');  // <![CDATA[
   function gohelpdesk() {
     if (($tablecolor eq '') || ($tablecolor eq '#FFFFFF')) {      var actiontype = null;
         $tablecolor = '#CCCCFF';      try {
     }          actiontype = parent.bodyframe.document.logproblem.action.value;
       }
     $r->print(<<END);      catch(error) {
 <html>          parent.bodyframe.location = "/adm/support?origurl=$displayurl";
 <head>          return;
 <title>Help Banner</title>      }
 <style type="text/css">      if (actiontype) {
 <!--          var loc = parent.bodyframe.location.href;
  a:link {text-decoration: none; color: $fontcolor; }          if (loc.indexOf("/adm/support") > -1) {
  a:visited {text-decoration: none; color: $fontcolor; }              if (parent.bodyframe.document.logproblem.action.value == "process") {
  a:active {text-decoration: none; color: $fontcolor; }                  if (validmail(parent.bodyframe.document.logproblem.email) == false) {
  a:hover {text-decoration: underline; color: $vlinkcolor; }                      alert("The e-mail address you entered: "+parent.bodyframe.document.logproblem.email.value+" is not a valid e-mail address.");
 -->                      return;
 </style>                  }
 </head>                  parent.bodyframe.document.logproblem.submit();
 $bodytag                  return;
 END              }
           }
           parent.bodyframe.location = "/adm/support?origurl=$displayurl";
           return;
       }
   }
   
   SCRIPT_ONE
           $scripttag .= (<<'SCRIPT_TWO');
   function validmail(field) {
       var str = field.value;
       if (window.RegExp) {
           var reg1str = "(@.*@)|(\\.\\.)|(@\\.)|(\\.@)|(^\\.)";
           var reg2str = "^.+\\@(\\[?)[a-zA-Z0-9\\-\\.]+\\.([a-zA-Z]{2,3}|[0-9]{1,3})(\\]?)$"; //"
           var reg1 = new RegExp(reg1str);
           var reg2 = new RegExp(reg2str);
           if (!reg1.test(str) && reg2.test(str)) {
               return true;
           }
           return false;
       }
       else
       {
   
           if(str.indexOf("@") >= 0) {
               return true;
           }
           return false;
       }
   }
   
   // ]]>
   </script>
   SCRIPT_TWO
       }
   
     if ($stayOnPage) {      if ($stayOnPage) {
         $r->print('<table width="700" border="0" cellspacing="0" cellpadding="0" height="55">');   $r->print(&Apache::loncommon::start_page('Help',$scripttag,
            {'no_secondary_menu' => 1,}));
     } else {      } else {
         $r->print('<table width="600" border="0" cellspacing="0" cellpadding="0" height="55">');          $r->print(&Apache::loncommon::start_page('Help',$scripttag,
                                                    {'only_body' => 1,}));
     }      }
     $r->print(<<END);      my $menu = &helpmenu_items($dom,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail,$stayOnPage);
   <tr height="50">      if ($menu) {
    <td width='5'>&nbsp;</td>          $r->print("<ul id=\"LC_secondary_menu\">$menu</ul>");
    <td>      }
     <fieldset><legend><img src="/adm/lonIcons/minilogo.gif" height='20' width='29' valign='bottom' />&nbsp;&nbsp;<b><font size="+1">LON-CAPA help/support</font></b></legend>      if ($stayOnPage && $env{'user.adv'}) {
  <table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="#000000">          $r->print('<br />');
   <tr>      } 
    <td>      $r->print(&Apache::loncommon::end_page());
     <table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#000000">  }
      <tr>  
       <td>  sub helpmenu_items {
        <table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="#ffffff">      my ($dom,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail,$stayOnPage) = @_;
         <tr>      my $location=&Apache::loncommon::lonhttpdurl("/adm");
          <td>      my $general_help = &Apache::loncommon::general_help();
   <table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#ffffff">      my %helpconfig = &Apache::lonnet::get_dom('configuration',['helpsettings'],$dom);
            <tr bgcolor="$tablecolor">      my %lt = &Apache::lonlocal::texthash(
 END                                              general       => 'General help',
     if (($component_url) || ($ENV{'user.adv'})) {                                              component     => 'Topic help',
         if ($component_url) {                                              faq           => 'FAQ',
             $r->print("                                              helpdesk      => 'Ask helpdesk',
             <td align=\"center\">&nbsp;<b><a href=\"$component_url\" target=\"bodyframe\">");                                              bugs          => 'Report a bug',
         } elsif ($ENV{'user.adv'}) {                                              manuals_web   => 'Online manuals',
             $r->print('<td align="center">&nbsp;<b><a href="/adm/help/nohelptopic.html" target="bodyframe">');                                              manuals_pdf   => 'Printable manuals',
         }                                              lastloc       => 'Go back',
         $r->print('                                              close         => 'Close',
   <image src="/adm/help/gif/smallHelp.gif" border="0" alt="(Topic help)" valign="middle" />&nbsp;Topic help</a></b>&nbsp;</td>');                                           );
       my $target = '_top';
       if (($env{'request.lti.login'}) && ($env{'request.lti.target'} eq 'iframe')) {
           $target = '_parent';
       }
       my %items = (
                       general => {
                                    href => '/adm/help/'.$general_help.'.hlp',
                                    img  => $location.'/help/help.png',
                                    alt  => $lt{'general'},
                                    text => $lt{'general'},
                                  },
                       component => {
                                      href => $component_url,
                                      img  => $location.'/help/help.png',
                                      alt  => $lt{'component'},
                                      text => $topic,
                                    },
                       faq      => {
                                      href => $faqbaseurl.'fom/cache/'.$faq.'.html',
                                      img  => $location.'/lonMisc/smallFAQ.gif',
                                      alt  => $lt{'faq'},
                                      text => $lt{'faq'},                                   
                                    },
                       helpdesk => {
                                      href    => '#',
                                      onclick => 'gohelpdesk()',
                                      img  => $location.'/lonIcons/helpdesk.gif',    
                                      alt  => $lt{'helpdesk'},
                                      text => $lt{'helpdesk'},
                                   },
                       bugs     => {
                                      href => $bugurl,
                                      img  => $location.'/lonMisc/smallBug.gif', 
                                      alt  => $lt{'bugs'},
                                      text => $lt{'bugs'},
                                   },
                       manuals_web  => {
                                          href => '',
                                          img  => $location.'/lonIcons/html.gif',
                                          alt  => $lt{'manuals_web'},
                                          text => $lt{'manuals_web'},
                                       },
                       manuals_pdf  => {
                                          href => '',
                                          img  => $location.'/lonIcons/pdf.gif',
                                          alt  => $lt{'manuals_pdf'},
                                          text => $lt{'manuals_pdf'},
                                       },
                       lastloc  => {
                                      href   => &HTML::Entities::encode($origurl,'"&<>'),
                                      img    => '/res/adm/pages/tolastloc.png',
                                      alt    => $lt{'lastloc'},
                                      text   => $lt{'lastloc'},
                                      target => $target,
                                   },
                       close    => {
                                      href   => 'javascript:window.close()',
                                      img    => $location.'/lonIcons/close.gif',
                                      alt    => $lt{'close'},
                                      text   => $lt{'close'},
                                      target => $target,
                                   },
       );
       my %help_submenu = (
                              manuals_web => [
                                               ['/adm/help/course.manual.access.hlp','Course Coordination','course'],
                                               ['/adm/help/author.manual.access.hlp','Authoring','author'],
                                             ],
                              manuals_pdf => [
                                               ['/adm/help/course.manual.pdf','Course Coordination','course'],
                                               ['/adm/help/author.manual.pdf','Authoring','author'],
                                             ],
                          );
       my @order = ('general');
       if ($component_url) {
           push(@order,'component');
     }      }
     if ($requestmail) {      if ($requestmail) {
         $r->print('          push(@order,'helpdesk');
             <td align="center">&nbsp;<b><a href="/adm/support?origurl='.&Apache::lonnet::escape($origurl).'&function='.$function.'" target="bodyframe"><image src="/adm/lonMisc/feedback.gif" border="0" alt="(Ask helpdesk)" valign="middle" />&nbsp;Ask helpdesk</a></b>&nbsp;</td>');  
     }      }
     if ($faq && $ENV{'user.adv'}) {      if ($env{'user.adv'} && $faq) {
         $r->print(<<END)          push(@order,'faq');
             <td align="center">      }
              &nbsp;<b><a href="$faqbaseurl/fom/cache/$faq.html" target="bodyframe"><image src="/adm/lonMisc/smallFAQ.gif" border="0" alt="(FAQ)" valign="middle" />&nbsp;FAQ</a></b>&nbsp;      if (($env{'user.adv'}) && (($helpconfig{'helpsettings'}{'submitbugs'} eq '1') || ($helpconfig{'helpsettings'}{'submitbugs'} eq ''))) {
             </td>          push(@order,'bugs');
 END  
     }  
     if ($ENV{'user.adv'}) {  
         $r->print(<<END)  
             <td align="center">&nbsp;<b><a href="$bugurl" target="bodyframe"><image src="/adm/lonMisc/smallBug.gif" border="0" alt="(Report a bug)" valign="middle" />&nbsp;Report a bug</a>&nbsp;</b></td>  
 END  
     }      }
     if ($stayOnPage) {      if ($stayOnPage) {
         $r->print(<<END);          push(@order,('manuals_web','manuals_pdf','lastloc'));
             <td align="center">&nbsp;<b><a href="$origurl" target="_top"><image src="/adm/lonIcons/move_up.gif" border="0" alt="(Return to last location)" valign="middle" />&nbsp;Return to last location</a></b>&nbsp;</td>      } else {
 END          push(@order,'close');
       }
       my $menu;
       foreach my $title (@order) {
           my $menuitem = $items{$title};
           next unless (ref($menuitem) eq 'HASH');
           if (defined($help_submenu{$title})) {
               my ($link,$target);
               if ($menuitem->{href} ne '') {
                   $link = $menuitem->{href};
                   $target = 'bodyframe';
               } else {
                   $link = '#';
               }
               my @helpsub;
               if (ref($help_submenu{$title}) eq 'ARRAY') {
                   foreach my $item (@{$help_submenu{$title}}) {
                       if (ref($item) eq 'ARRAY') {
                           if (($item->[2] eq 'course') || ($item->[2] eq 'author')) {
                               next unless($env{'user.adv'});
                           }
                           push(@helpsub,$item);
                       }
                   }
                   if (@helpsub > 0) {
                       my $img;
                       if ($menuitem->{img}) {
                           $img = '<img class="LC_noBorder" style="vertical-align:top" src="'.$menuitem->{img}.'" alt="'.$menuitem->{alt}.'" />';
                       }
                       $menu .= &create_submenu($link,$img,$target,$menuitem->{text},\@helpsub,1);
                   } elsif ($link ne '#') {
                       $menu .= '<li><a href="'.$link.'" target="'.$target.'">'.$menuitem->{text}.'</a></li>';
                   }
               }
           } else {
               $menu .= &build_menuitem($menuitem);
           }
       }
       return $menu;
   }
   
   sub build_menuitem {
       my ($menuitem) = @_;
       return '' unless(ref($menuitem) eq 'HASH');
       my $link;
       if ($menuitem->{img}) {
           $link = '<img style="vertical-align:top" class="LC_noBorder" src="'.$menuitem->{img}.'" alt="'.$menuitem->{alt}.'" />&nbsp;';
       }
       if ($menuitem->{text}) {
           $link .= $menuitem->{text};
       }
       my $target;
       if ($menuitem->{target}) {
           $target = $menuitem->{target};
     } else {      } else {
         $r->print(<<END);          $target = 'bodyframe';
             <td align="center">&nbsp;<b><a href="javascript:window.close()" target="_top"><image src="/adm/lonIcons/closepage.gif" border="0" alt="(Close window)" valign="bottom" />&nbsp;Close</a></b>&nbsp;</td>      }
 END      my $onclick;
     }      if ($menuitem->{onclick}) {
     $r->print(<<END);          $onclick = ' onclick="'.$menuitem->{onclick}.';return false"';
            </tr>      }
           </table>      return '<li><a href="'.$menuitem->{href}.'" target="'.$target.'"'.$onclick.'>'.$link.'</a></li>',
          </td>  }
         </tr>  
        </table>  sub create_submenu {
       </td>      my ($link,$img,$target,$title,$submenu,$translate) = @_;
      </tr>      return unless (ref($submenu) eq 'ARRAY');
     </table>      my $disptarget;
    </td>      if ($target ne '') {
   </tr>          $disptarget = ' target="'.$target.'"';
  </table>      }
 </fieldset>      my $menu = '<li class="LC_hoverable">'.$img.
   </td>                 '<a href="'.$link.'"'.$disptarget.'>'.
   <td width='5'>&nbsp;</td>                 '<span class="LC_nobreak">'.$title.
  </tr>                 '<span class="LC_fontsize_small" style="font-weight:normal;">'.
  <tr height='5'>                 ' &#9660;</span></span></a>'.
   <td colspan='3' height='5'>&nbsp;</td>                 '<ul>';
  </tr>      my $count = 0;
 </table>      my $numsub = scalar(@{$submenu});
 </body>      foreach my $item (@{$submenu}) {
 </html>          $count ++;
 END          if (ref($item) eq 'ARRAY') {
               my $href = $item->[0];
               my $borderbot;
               if ($count == $numsub) {
                   $borderbot = 'border-bottom:1px solid black;';
               }
               $menu .= '<li style="margin:0;padding:0;'.
                        $borderbot.'"><a href="'.$href.'" target="bodyframe">';
               if ($translate) {
                   $menu .= &mt($item->[1]);
               } else {
                   $menu .= $item->[1];
               }
               $menu .= '</a></li>';
           }
       }
       $menu .= '</ul></li>';
       return $menu;
 }  }
   
 sub display_help_mainpage {  sub display_help_mainpage {
     my ($r,$color,$function,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail) = @_;      my ($r,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail,$stayOnPage) = @_;
     my $bodytag = &Apache::loncommon::bodytag('',$function,'topmargin="0" marginheight="0"',1);  
     $bodytag=~s/[\n\r]/ /g;  
     my %lt =&Apache::lonlocal::texthash(      my %lt =&Apache::lonlocal::texthash(
         'heco' => 'Help Content',  
         'topp' => 'Topic Page',          'topp' => 'Topic Page',
         'chen' => 'Choose an entry below to go directly to a relevant help page',          'chen' => 'Choose an entry below to go directly to a relevant help page',
         'orto' => 'or to submit a help request to the LON-CAPA support staff at your institution.',          'orto' => 'or to submit a help request to the LON-CAPA support staff at your institution.',
         'vthp' => 'Visit the help page for ',          'vthp' => 'Visit the help page for ',
         'disp' => 'Display the page in the inline help system that covers this topic.',          'disp' => 'Display the page in the inline help system that covers this topic.',
         'crac' => 'Create an account for yourself in the LON-CAPA Bugzilla tracking system, if you wish to report bugs you have encountered in the LON-CAPA software, or if you have suggestions for improvements in LON-CAPA.',          'crac' => 'Create an account for yourself in the LON-CAPA Bugzilla tracking system, if you wish to report bugs you have encountered in the LON-CAPA software, or if you have suggestions for improvements in LON-CAPA.',
         'inhs' => 'Inline help system for',  
         'coth' => 'Consult the inline help system for this topic.',  
         'cont' => 'Contact the LON-CAPA support team',          'cont' => 'Contact the LON-CAPA support team',
         'suhr' => 'Submit a help request to the team responsible for LON-CAPA support at this institution.',          'suhr' => 'Submit a help request to the team responsible for LON-CAPA support at this institution.',
         'faqo' => 'FAQ-O-Matic Help system',          'faqo' => 'FAQ-O-Matic Help system',
Line 201  sub display_help_mainpage { Line 389  sub display_help_mainpage {
         'suim' => ' Suggested improvements may include additional functionality, improved usability, or changes to wording used in LON-CAPA pages, including the embedded help system.'          'suim' => ' Suggested improvements may include additional functionality, improved usability, or changes to wording used in LON-CAPA pages, including the embedded help system.'
     );      );
   
     $r->print(<<END);      if ($stayOnPage) {
 <html>   $r->print(&Apache::loncommon::start_page('Help Content',undef,
  <head>                   {'no_secondary_menu' => 1,}));
   <title>$lt{'heco'}</title>      } else {
  </head>          $r->print(&Apache::loncommon::start_page('Help Content',undef,
 $bodytag                                                   {'only_body' => 1,}));
 END      }
     $r->print($lt{'chen'});      my $target = '_top';
       if (($env{'request.lti.login'}) && ($env{'request.lti.target'} eq 'iframe')) {
           $target = '_parent';
       }
       if ($stayOnPage) {
           $r->print('<div>');
       } 
       $r->print('<b>'.$lt{'chen'});
     if ($requestmail) {      if ($requestmail) {
         $r->print(', '.$lt{'orto'});          $r->print(', '.$lt{'orto'});
     } else {      } else {
         $r->print(".");          $r->print(".");
     }      }
       $r->print('</b>');
     if ($topic) {      if ($topic) {
         if ( ($component_url) || ($ENV{'user.adv'}) ) {          if ( ($component_url) || ($env{'user.adv'}) ) {
             if ($component_url) {              if ($component_url) {
                 $r->print("                  $r->print("
           <ul>            <ul>
Line 223  END Line 419  END
           </ul>            </ul>
           <p>$lt{'disp'}</p>            <p>$lt{'disp'}</p>
                 ");                  ");
             } elsif ($ENV{'user.adv'}) {  
                 $r->print("  
               <ul>  
                <li><td align=\"center\">&nbsp;<a href=\"/adm/help/nohelptopic.html\">$lt{'inhs'} $topic</a></li></ul>  
                <p>$lt{'coth'}</p>");  
             }              }
         }          }
     }      }
     if ($requestmail) {      if ($requestmail) {
         $r->print("          $r->print("
           <ul>            <ul>
            <li><a href=\"/adm/support?origurl=".&Apache::lonnet::escape($origurl)."&function=$function\">$lt{'cont'}</a></li>             <li><a href=\"/adm/support?origurl=".&escape($origurl)."\">$lt{'cont'}</a></li>
           </ul>            </ul>
           <p>$lt{'suhr'}</p>            <p>$lt{'suhr'}");
           <ul>           unless ($env{'user.adv'}) {
         ");               $r->print('<br />'.
                          &mt('[_1]Note[_2]: questions about course content should not be directed to the support team, but instead should be sent to the course instructor.'). 
                          ' '.
                          &mt('This can be done by clicking the [_1]Communicate[_2] link or the "Send Feedback" link when viewing a content page.',
                             '<a href="/adm/communicate" target="'.$target.'">','</a>')); 
            }
            $r->print("</p>");
     }      }
     if ($faqbaseurl && $ENV{'user.adv'}) {      if ($faqbaseurl && $env{'user.adv'}) {
         if (!defined($faq) ||$faq eq '') {          if (!defined($faq) ||$faq eq '') {
             $faq = '1';              $faq = '1';
         }          }
         $r->print("          $r->print("
             <ul>
            <li><a href=\"$faqbaseurl/fom/cache/$faq.html\">$lt{'faqo'}</a></li>             <li><a href=\"$faqbaseurl/fom/cache/$faq.html\">$lt{'faqo'}</a></li>
           </ul>            </ul>
           <p>$lt{'tfaq'}</p>            <p>$lt{'tfaq'}</p>
         ");          ");
     }      }
     if ($bugurl && $ENV{'user.adv'}) {      if ($bugurl && $env{'user.adv'}) {
         $bugurl .= '?'.$bug;          $bugurl .= '?'.$bug;
         $r->print("          $r->print("
           <ul>            <ul>
Line 259  END Line 457  END
           <p>$lt{'crea'} $lt{'suim'}</p>            <p>$lt{'crea'} $lt{'suim'}</p>
         ");          ");
     }      }
     $r->print(<<END);      if ($stayOnPage) {
  </body>          $r->print('</div>');
 </html>      }
 END      $r->print(&Apache::loncommon::end_page());
 }  }
   
 1;  1;

Removed from v.1.9  
changed lines
  Added in v.1.46


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>