#!/usr/local/bin/perl ############################################## # # EveryAuction # by Matt Hahnfeld, EverySoft # # The premiere freeware auction software from # the makers of EveryChat(tm). # # Version 1.01 (5/10/98) # # You may modify this script for your personal # or company/client use, but you may not # redistribute any modifications without # written permission from the author. There # are no warranties or guarantees of any # kind placed on this script. # # REDISTRIBUTION IN ANY FORM IS STRICTLY # PROHIBITED! # # (c) 1998 EverySoft # # http://www.everysoft.com/auction/ # ############################################## ############################################## # The input query string is in the form # auction.cgi?[category]&[number]&[r|n|u|c|v] # # If nothing is given, the script will # display the categories in the auction. # # If category dir is given, the # script will display the items in the # category. # # If category dir is given and message # number is given, the script will display # the item. # # If category dir is given and message # number is given, and the letter r is given # then the record will be deleted from # the database. # # If category dir is given and message # number is given, and the letter n is given # then a new record can be created. The # message number given is ignored. # # If category dir is given and message # number is given, and the letter u is given # then a new user registration can be # created. Both the message number and # category given are ignored. # # If category dir is given and message # number is given, and the letter c is given # then a user registration can be # changed. Both the message number and # category given are ignored. # # If category dir is given and message # number is given, and the letter v is given # then a user may view his/her closed item # status. Both the message number and # category given are ignored. # ############################################## # Configuration Section # Edit these variables! # The Base Directory. We need an # absolute path for the base directory. # Include the trailing slash. THIS SHOULD # NOT BE WEB-ACCESSIBLE! $basepath = '/digiweb/usr/netlaunch/comicgallery.com/public_html/auction/'; # Closed Auction Directory # This is where closed auction items are stored. # Leave this blank if you don't want to store # closed auctions. It can potentially take # up quite a bit of disk space. $closedir = 'closed'; # User Registration Directory # This is where user registrations are stored. # Leave this blank if you don't want to # require registration. It can potentially # take up quite a bit of disk space. $regdir = 'reg'; # List each directory and its associated # category name. These directories should # be subdirectories of the base directory. %category = ( sericels => 'Seri Cels', lihtos => 'Lithographs', HandCels => 'Hand Painted Cels', ); # This is the password for deleting auction # items. If it is left blank, anyone may # delete entries. $adminpass = 'callex'; # This must be the valid IP ADDRESS of an # SMTP server. It is used to mail auction # notifications. If the e-mail system is # not working, this is what you should # check first. $mailserver = "206.161.225.88"; # This line should point to the URL of # your server. It will be used for sending # "you have been outbid" e-mail. The script # name and auction will be appended to the # end automatically, so DO NOT use a trailing # slash. If you do not want to send outbid # e-mail, leave this blank. $scripturl = "comicgallery.com"; # This will let you define colors for the # tables that are generated and the # other page colors. The default colors # create a nice "professional" look. Must # be in hex format. $colorbg = '#041467'; $colortext = '#dfb80a'; $colorlink = '#0bf7de'; $colorvlink = '#fbee23'; $coloralink = '#fbee23'; $colortablehead = '#004040'; $colortablebody = '#770038'; # Site Name (will appear at teh top of each page) $sitename = 'Comic Gallery'; # Sniper Protection... How many minutes # past last bid to hold auction. If auctions # should close at exactly closing time, set # to zero. $aftermin = 5; # File locking enabled? Should be 1 (yes) # for most systems, but set to 0 (no) if you # are getting flock errors or the script # crashes. $flock = 1; # User Posting Enabled- 1=yes 0=no $newokay = 1; ############################################## # Main Program # You do not need to edit anything below this # line. ############################################## # Print The Page Header # print "Content-type: text/html\n\n"; print "
| $sitename Online Auction | \n";
print "
\n"; # ############################################## &get_form_data; # parse arguments from post @ARGV = split(/\\*\&/, $ENV{'QUERY_STRING'}); $ARGV[0] =~ s/\W//g; $ARGV[1] =~ s/\D//g; if ($form{'action'} eq 'bid') { &procbid; } elsif ($form{'action'} eq 'new') { &procnew; } elsif ($form{'action'} eq 'reg') { &procreg; } elsif ($form{'action'} eq 'creg') { &proccreg; } elsif ($form{'action'} eq 'repost') { &newitem; } elsif ($form{'action'} eq 'closeditems1') { &viewclosed1; } elsif ($form{'action'} eq 'closeditems2') { &viewclosed2; } elsif ($form{'searchstring'}) { &procsearch; } elsif ($ARGV[2] eq 'u') { &newreg; } elsif ($ARGV[2] eq 'c') { &changereg; } elsif ($ARGV[2] eq 'v') { &viewclosed; } elsif ($ARGV[2] eq 'n') { &newitem; } elsif (($regdir ne "") && ($ARGV[0] eq $regdir)) { &dispcat; } # be sure nobody is trying to hack the user dir elsif (!(($ARGV[0]) && (-d "$basepath$ARGV[0]"))) { &dispcat; } elsif ($ARGV[2] eq 'r') { &remitem; } elsif (!(($ARGV[1]) && (-f "$basepath$ARGV[0]/$ARGV[1].dat"))) { &displist; } else { &dispitem; } ############################################## # Print The Page Footer # print "
[Category List]";
print " [Post New Item]" if ($newokay);
print " [New Registration] [Change Registration]" if ($regdir);
print " [Closed Auctions]" if ($regdir) && ($closedir);
# Please do not delete or change the following line!!!
print "";
print "
Powered By Netlaunch
| Category | Items |
| $category{$key} | $numfiles |
| Item | Closes | Num Bids | High Bid |
| $title$camera | $closetime[4]/$closetime[3] | $#bids | \$$lastbid[2] |
|