#!/usr/bin/perl #sponsors2.pl #Loads all of the Sponsors from sponsors.lst and displays them require "flush.pl"; require "cgi-lib.pl"; print &PrintHeader(); &ReadParse(*article); open (TRASHY, ">/tmp/trashed"); foreach (keys(%article)){ $article{$_}=~s/\0//; $article{$_}=~s/[%&<>]//g; #this is a mystery!!! $thelength=$article{$_} if (/length/); } $ArtNumber = $article{articlenumber}; $ArticleDate = $article{tocdate}; #################################################### # # Path for sponsors.lst $SPONSORSLISTPATH = "/serv/htdocs/"; # # path for sponsor's images $SPONSORIMAGEPATH = "/sponsors/"; # # path for image maps $ARTPATH = "/art/"; # # path for toc.html $TOCHTMLPATH = "/usr/people/admin/sn/maildocs/articles/"; # #################################################### print "\n"; printf "\nHPCwire Sponsors\n\n"; print "\n"; print "
\n

HPCWire's Sponsors

\n"; if (!(open (SPONSORS, $SPONSORSLISTPATH."sponsors.lst"))){ print STDOUT "
Unfortunately, the Sponsors file is temporarily suspended. Please use the back button to return to HPCWire.";} while(){ while (s/([^=]+)=([^=]+)=(\S*)\n//){ if ("$1" eq "NoOne") {next;} if (($3 ne "none") && ($3 ne "")){ printf STDOUT "\n\n\"%s\"\n", $3, $SPONSORIMAGEPATH, $2, $1; } else{printf STDOUT "\n\"%s\"", $SPONSORIMAGEPATH, $2, $1; } print "
"; } } print ""; exit;