#!/usr/bin/perl require "../../cgi-lib/lkhtml.pm"; use CGI qw/:standard/; my @body, @html; $basefile = $ARGV[0]; $dir = "content"; $ndxfile = "$dir/$basefile.ndx"; $htmlfile = "$dir/$basefile.html"; open(NDX, "< $ndxfile"); @lines = ; close(NDX); $title=$lines[0]; push @html, &show_html; push @html, &show_header("TSB $title"); open(HTMLFILE, "< $htmlfile") or die "Could not open $htmlfile for reading: $!\n"; while () { if (substr($_,0,5) ne "show_") { push @body, $_; } else { ($func,@args) = split(' ',$_); push @body, &$func(@args); } } close(HTMLFILE); push @html, &show_top_section("TSB $title",@body); push @html, &show_back_link; push @html, &show_end_html; print @html; exit;