Diff for /loncom/interface/lonhelpmenu.pm between versions 1.3 and 1.7

version 1.3, 2004/07/03 19:33:30 version 1.7, 2004/07/03 20:45:23
Line 69  sub handler { Line 69  sub handler {
 sub display_help_banner {  sub display_help_banner {
     my ($r,$color,$function,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail) = @_;      my ($r,$color,$function,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail) = @_;
     my $bodytag = &Apache::loncommon::bodytag('',$function,'rightmargin="0" leftmargin="0" marginwidth="0" topmargin="1" marginheight="1"',1);      my $bodytag = &Apache::loncommon::bodytag('',$function,'rightmargin="0" leftmargin="0" marginwidth="0" topmargin="1" marginheight="1"',1);
     $bodytag=~/[\n\r]/ /g;      $bodytag=~s/[\n\r]/ /g;
     my $fontcolor = &Apache::loncommon::designparm($function.'.font');      my $fontcolor = &Apache::loncommon::designparm($function.'.font');
     my $alinkcolor = &Apache::loncommon::designparm($function.'.alink');      my $alinkcolor = &Apache::loncommon::designparm($function.'.alink');
     my $vlinkcolor = &Apache::loncommon::designparm($function.'.vlink');      my $vlinkcolor = &Apache::loncommon::designparm($function.'.vlink');
Line 120  END Line 120  END
         if ($component_url) {          if ($component_url) {
             $r->print("              $r->print("
             <td align=\"center\">&nbsp;<b><a href=\"$component_url\" target=\"bodyframe\">");              <td align=\"center\">&nbsp;<b><a href=\"$component_url\" target=\"bodyframe\">");
         } elsif ($ENV{'user.adv'}) {      $r->print('
      <image src="/adm/help/gif/smallHelp.gif" border="0" alt="(Topic help)" valign="middle" />&nbsp;Topic help</a></b>&nbsp;</td>');
           } elsif (0 && $ENV{'user.adv'}) {
       #FIXME doing this in JS is problematic since JS can't control frames that go to outside sites
             $r->print('<td align="center">&nbsp;<b><a href="javascript:noTopic()" target="bodyframe">');              $r->print('<td align="center">&nbsp;<b><a href="javascript:noTopic()" target="bodyframe">');
         }          }
         $r->print('  
    <image src="/adm/help/gif/smallHelp.gif" border="0" alt="(Topic help)" valign="middle" />&nbsp;Topic help</a></b>&nbsp;</td>');  
     }      }
     if ($requestmail) {      if ($requestmail) {
         $r->print('          $r->print('
             <td align="center">&nbsp;<b><a href="/adm/support?origurl='.$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>');              <td align="center">&nbsp;<b><a href="/adm/support?origurl='.$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 ($ENV{'user.adv'}) {      if ($faq && $ENV{'user.adv'}) {
         $r->print(<<END)          $r->print(<<END)
             <td align="center">              <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;               &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;
             </td>              </td>
   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>              <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  END
     }      }
Line 167  END Line 172  END
 sub display_help_mainpage {  sub display_help_mainpage {
     my ($r,$color,$function,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail) = @_;      my ($r,$color,$function,$faq,$bug,$topic,$component_url,$origurl,$bugurl,$faqbaseurl,$requestmail) = @_;
     my $bodytag = &Apache::loncommon::bodytag('',$function,'topmargin="0" marginheight="0"',1);      my $bodytag = &Apache::loncommon::bodytag('',$function,'topmargin="0" marginheight="0"',1);
     $bodytag=~/[\n\r]/ /g;      $bodytag=~s/[\n\r]/ /g;
     $r->print(<<END);      $r->print(<<END);
 <html>  <html>
  <head>   <head>
   <title>Help Content</title>    <title>Help Content</title>
   <script type="text/javascript">    <script type="text/javascript">
 function noTopic() {  function noTopic() {
     bodyframe.document.write("<html><head><title>Topic Page</title></head>$bodytag")      bodyframe.document.write('<html><head><title>Topic Page</title></head>$bodytag')
     bodyframe.document.write("The LON-CAPA help system does not currently include a specific pop-up help item for this topic. You may wish to consult the LON-CAPA <a href='/adm/help/author.manual.pdf'>Authoring Manual</a> or the <a href='/adm/help/course.manual.pdf'>Course Coordinator Manual</a>.")      bodyframe.document.write("The LON-CAPA help system does not currently include a specific pop-up help item for this topic. You may wish to consult the LON-CAPA <a href='/adm/help/author.manual.pdf'>Authoring Manual</a> or the <a href='/adm/help/course.manual.pdf'>Course Coordinator Manual</a>.")
     bodyframe.document.write("</body></html>")      bodyframe.document.write("</body></html>")
     body.document.close()      body.document.close()

Removed from v.1.3  
changed lines
  Added in v.1.7


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