[Bio] / FigKernelPackages / HTML.pm Repository:
ViewVC logotype

Diff of /FigKernelPackages/HTML.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.41, Thu Apr 28 20:56:37 2005 UTC revision 1.42, Tue May 3 17:38:50 2005 UTC
# Line 22  Line 22 
22  sub compute_html_header  sub compute_html_header
23  {  {
24      shift if UNIVERSAL::isa($_[0],__PACKAGE__);      shift if UNIVERSAL::isa($_[0],__PACKAGE__);
25      my($additional_insert,$user) = @_;      my($additional_insert, $user, %options ) = @_;
26      my $html_hdr_file = "./Html/html.hdr";  
27        my $header_name = $options{header_name} ? $options{header_name} : "html.hdr";
28        my $tail_name = $options{tail_name} ? $options{tail_name} : "html.tail";
29    
30        my $html_hdr_file = "./Html/$header_name";
31      if (! -f $html_hdr_file)      if (! -f $html_hdr_file)
32      {      {
33          $html_hdr_file = "$FIG_Config::fig/CGI/Html/html.hdr";          $html_hdr_file = "$FIG_Config::fig/CGI/Html/$header_name";
34      }      }
35      my @html_hdr = &FIG::file_read($html_hdr_file);      my @html_hdr = &FIG::file_read($html_hdr_file);
36      push( @html_hdr, "<br><a href=\"index.cgi?user=$user\">FIG search</a>\n" );  
37        $options{no_fig_search} or push( @html_hdr, "<br><a href=\"index.cgi?user=$user\">FIG search</a>\n" );
38    
39      if (@html_hdr)      if (@html_hdr)
40      {      {
41          my $insert_stuff;          my $insert_stuff;
42    
43            if (not $options{no_release_info})
44            {
45          my @ver = &FIG::file_head("$FIG_Config::fig_disk/CURRENT_RELEASE", 1);          my @ver = &FIG::file_head("$FIG_Config::fig_disk/CURRENT_RELEASE", 1);
46          my $ver = $ver[0];          my $ver = $ver[0];
47          chomp $ver;          chomp $ver;
# Line 45  Line 53 
53          }          }
54          my $host = &FIG::get_local_hostname();          my $host = &FIG::get_local_hostname();
55          $insert_stuff = "SEED version <b>$ver</b> on $host";          $insert_stuff = "SEED version <b>$ver</b> on $host";
56            }
57    
58          if ($additional_insert)          if ($additional_insert)
59          {          {
60              $insert_stuff .= "<br>" . $additional_insert;              $insert_stuff .= "<br>" . $additional_insert;
# Line 83  Line 93 
93      # Find the HTML header      # Find the HTML header
94      #      #
95    
96      my $html_tail_file = "./Html/html.tail";      my $html_tail_file = "./Html/$tail_name";
97      if (! -f $html_tail_file)      if (! -f $html_tail_file)
98      {      {
99          $html_tail_file = "$FIG_Config::fig/CGI/Html/html.tail";          $html_tail_file = "$FIG_Config::fig/CGI/Html/$tail_name";
100      }      }
101    
102      my $user = $cgi->param('user') || "";      my $user = $cgi->param('user') || "";

Legend:
Removed from v.1.41  
changed lines
  Added in v.1.42

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3