[Bio] / FigWebServices / DocDirectory.cgi Repository:
ViewVC logotype

Annotation of /FigWebServices/DocDirectory.cgi

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (view) (download)

1 : parrello 1.1 #!/usr/bin/perl -w
2 :    
3 :     BEGIN {
4 :     # Print the HTML header.
5 :     print "CONTENT-TYPE: text/html\n\n";
6 :     }
7 :    
8 :     =head1 Documentation Directory
9 :    
10 :     This script generates the directory of documentation modules for FIG. The user can
11 :     click on a module name and it will automatically pop up the documentation for that
12 :     module.
13 :    
14 :     =cut
15 :    
16 :     use strict;
17 :     use CGI;
18 :     use Tracer;
19 :     use PageBuilder;
20 :    
21 :     my $dir = "$FIG_Config::cgi_base/Html/pod_docs";
22 :     my $links = "";
23 :     # Open the documentation directory, and build a table of contents for it.
24 :     if (-d $dir) {
25 :     my @files = sort (Tracer::OpenDir($dir, 1));
26 :     for my $file (@files) {
27 :     if ($file =~ /^(.+)\.html$/) {
28 :     my $fileName = $1;
29 :     $links .= "<a href=\"$FIG_Config::cgi_url/Html/pod_docs/$file\" target=\"mainFrame\">$fileName</a><br>\n";
30 :     }
31 :     }
32 :     print PageBuilder::Build("<$FIG_Config::cgi_base/Html/DirectoryTemplate.htm",
33 :     { index => $links });
34 :     }
35 :    
36 :     1;

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3