#!/usr/bin/perl ### Display all (or selected) files in directory. (+++ subdirs, too?) ### Display TITLE/ABSTRACT info. ### head.html and tail.html are also displayed. ######################################################################## ### Copyright (C) Tripodics.com ### Author: Bruce A. Martin ### File Name: abstract.pl ### Versions: ### 1.9 bam:2009/06/04 Bugler ### 1.6 bam:2007/07/23 Remove heading. (Use head.html) ### 1.5 bam:2006/01/20 Move head & tail to format/ ### 1.4 bam:2004/02/27 PIX ### 1.3 bam:2004/02/22 HTML only. ### 1.2 bam:2004/02/22 Use tighter Regexp control. (Rename "abstract.pl") ### 1.1 bam:2004/02/22 Extract descriptions from HTML ### 0.0 bam:2003/11/20 ######################################################################### use strict; use CGI qw/:standard :newtag/; #?? use "_getargs.txt"; my $NL = "\n"; my $Q = '"'; print header; # html format is permitted to output. #### Try some tricks, from html(); #-- head( title( "Abstracts" ) ); print "
"; print ''; my $ff=$f; $ff =~ s/^\.\///; print ''; print "$ff"; print ""; #print "$f"; #--print "$f \n"; print ''; ## Display file name and info ## print " | "; print ''; &shownotags( $f, $max ); print ''; print " | "; } # elsif ( $f =~ /\.pl*$/i ) { # print ''; # &showtext( $f, $max ); # print ''; ## } # elsif ( $f =~ /\.gif$/i ) { # print "GIF: "; # print ''; # print ''; # print ''; # } # elsif ( $f =~ /\.jp[e]*g$/i ) { # print "JPEG: "; # print ''; # print ''; # print ''; # } # ## Check file type; display if text. # elsif ( -T $f ) { # &showtext( $f, $max ); # } # elsif ( -d $f ) { # print " -- DIRECTORY"; # my $dd = $path . $f; # my @ddfiles; # opendir(DD,$dd) or print ' [[[[ Cannot open DIR. ]]]]'; # @ddfiles = grep !/^\./, readdir DD; # closedir DD; # print "