|
## DO NOT EDIT BELOW THIS LINE! ###
###################################
$|++;
use CGI;
$q = new CGI;
## END - DO NOT EDIT ABOVE THIS LINE ##
#######################################
$server_name = $ENV{'SERVER_NAME'} if ($server_name eq "");
$script_url = $ENV{'SCRIPT_NAME'};#Url of your auctionweaver.pl script
########################
# If $email_templates_dir points to a valid directory ..
# upload the following fi#les --- open each file to find the appropriate variables in a sample template
$dutch_auction_status_message = "dastatus.tlt" ;#dutch auction status message
$bid_passed_message = "bpassed.tlt";#message to be passed to the next lower bidder for normal auction
$winner_message = "wmessage.tlt";#winner message for top bidder-normal auction
$winner_message_rb = "wmessagerb.tlt";#winner message for top bidder who has bid less than reserve bid
$seller_message = "smessage.tlt";#seller messgae for normal auction
$winners_message_da = "wmessageda.tlt";#winners message for ALL dutch auction winners
$seller_message_da = "smessageda.tlt";#seller message for dutch auction
$login_message = "lmessage.tlt";#initial login info
########################
if ($ENV{'SCRIPT_FILENAME'}) {
$script_filename = $ENV{'SCRIPT_FILENAME'};
$script_filename =~ s/\\/\//g;
} elsif ($ENV{'PATH_TRANSLATED'}) {
$script_filename = $ENV{'PATH_TRANSLATED'};
$script_filename =~ s/\\/\//g;
}
@all = split(/\// , $script_filename);
$cgifile = $all[$#all];
if ($data_path eq "") {
($data_path = $script_filename) =~ s/\/$cgifile$// ;
$data_path .= "/DATA";
}
umask(000);
$datapermissions = oct($datapermissions);
$registerpermissions = oct($registerpermissions);
$closedpermissions = oct($closedpermissions);
$categorypermissions = oct($categorypermissions);
mkdir ("$data_path" , $datapermissions);
chmod ($datapermissions, "$data_path");
if ($require_user_reg == 1)
{
$register_path = $data_path."/register";
mkdir ("$register_path" , $registerpermissions);
chmod ($registerpermissions, "$register_path");
}
#^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
#CONFIGURABLE OPTIONS END HERE
#^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
$f = 0;
$version = "1.08";
$links = <<12345;
Search
|| Categories ||
Category Admin ||
Add Item
12345
$links .= <<12345 if ($require_user_reg == 1);
||
Register ||
Edit User Info ||
View Closed Auctions
12345
# $links .= <<12345 if ($keep_closed_auctions == 1);
# 12345
&get_cat;
&get_numberof_items;
$flag1 = $q->param('flag1');
&first if ($flag1 eq "");
$addcat = $q->param('addcat');
&formcat if ($addcat eq "1");
@pnames = $q->param;
foreach $pp(@pnames)
{
if ($q->param($pp) eq 'Delete' && $addcat ne "")
{
&delete_cat($pp);
exit(1);
}
}
if ($addcat eq "2") {
&addcat;
&get_cat;
&get_numberof_items;
&formcat;
}
$catdir = $q->param('catdir');
## Added 105 ##
if (($catdir) && (!($catdir =~ /^cat[0-9]+$/))) {
print "Content-type: text/html\n\n";
print "$catdir is not an Auction Weaver category directory "; exit; } $catdir =~ s/\.\.\\//g; $catdir =~ s/\.\.//g; $catdir =~ s/\///g; ## Added 105 ## ## Added 105 ## $item = $q->param('item'); $additem = $q->param('additem'); $additemflag = $q->param('additemflag'); $preview = $q->param('preview'); $addregister = $q->param('addregister'); $register = $q->param('register'); $edit = $q->param('edit'); $editactual = $q->param('editactual'); $fromfile = $q->param('fromfile'); ## Added 105 ## &fromcheck; $fromfile =~ s/\.\.\///g; $fromfile =~ s/\.\.//g; $fromfile =~ s/\///g; ## Added 105 ## $placebid = $q->param('placebid'); $closed = $q->param('closed'); $closed1 = $q->param('closed1'); $closed2 = $q->param('closed2'); $search = $q->param('search'); $fromsearch = $q->param('fromsearch'); $adminsection = $q->param('adminsection'); $logged = $q->param('logged'); &admin_login if ($adminsection ne ""); &admin_check if ($logged ne ""); &expand_cat($catdir) if ($catdir ne "" && $item eq "" && $fromfile eq ""); &form_item if ($additem ne "" && $additemflag eq ""); &preview if ($preview ne ""); &add_item if ($additemflag ne ""); &form_register if ($register ne "" && $addregister eq ""); &add_user if ($addregister ne ""); &form_edit if ($edit ne "" && $editactual eq ""); &edit if ($editactual ne ""); &show_item if ($fromfile ne "" && $placebid eq ""); &place_bid if ($placebid ne ""); &form_closed if ($closed ne ""); &closed1 if ($closed1 ne ""); &closed2 if ($closed2 ne ""); &form_search if ($search ne ""); &search if ($fromsearch ne ""); exit(1); sub search { &print_header; # print <<"12345"; #
Category |
Item |
Closes |
#
Bids |
Highest
Bid |
|
| $caty | $itemname | $closetime[4]/$closetime[3] | $#bids | $lastbid[2] |
| $caty | $itemname | $closetime[4]/$closetime[3] | $#bids | $lastbid[2] |
| USERNAME SEARCH | |
| KEYWORD SEARCH |
|
$image $desc Bids |
| Username |
|
Bid value |
| Username : | $firstbid[0] |
| Email : | $firstbid[1] |
| Item placed in auction | $dtt |
| Name : | $firstbid[4] |
| Street address : | $firstbid[5] |
| City : | $firstbid[6] |
| State : | $firstbid[7] |
| Zip : | $firstbid[8] |
| Username : | $lastbid[0] |
| Email : | $lastbid[1] |
| Bid placed on | $dtt |
| Name : | $lastbid[4] |
| Street address : | $lastbid[5] |
| City : | $lastbid[6] |
| State : | $lastbid[7] |
| Zip : | $lastbid[8] |
| Highest Bid : $currency$lastbid[2] |
|
|
| $linebid[0] |
| Closed Items for $name |
| Username | |
| Password | |
|
|
|
| $username , Your bid for $currency$bid has been placed on $itemname ( $itemno ) exactly at $dtime. |
| $links | $itemnameif ($image) { print <<"12345"; EOF } print <
# #
ITEM CLOSED FOR BIDDING "; #exit; &item_closed; } else { &form_for_placing_bid; &print_footer; } } sub form_for_placing_bid { ## MODIFIED BY DIRAN #$data_path =~ s/..\///g; ## Added 105 ## if (!($catdir =~ /^cat[0-9]+$/)) { print "Content-type: text/html\n\n"; print "$catdir is not an Auction Weaver category directory. "; exit; } ## Added 105 ## $catdir =~ s/\.\.\\//g; $catdir =~ s/\.\.//g; $catdir =~ s/\///g; ## Added 105 ## unless ($catdir) { print "Content-type: text/html\n\n"; print "You have not chosen a category. "; exit; } $fromfile =~ s/\.\.\///g; $fromfile =~ s/\.\.//g; $fromfile =~ s/\///g; &fromcheck; ## MODIFIED BY DIRAN $atleast = $lastbid[2] + $bidinc; if ($noitems > 1) { # $firstbid[2] = sprintf ("%.2f",$firstbid[2]); $vbid = $firstbid[2] + $bidinc if ($noitems > 1); $vbid = sprintf ("%.2f",$vbid); print <<"12345"; Place Bid Last Bid : $currency$lastbid[2] Your Bid must be at least Start bid $currency$vbid Place Bid Last Bid : $currency$lastbid[2] Your Bid must be at least $currency$atleast $error_message | |||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
| Edit User Information |
|
|
| $error_message | |
| *Username | |
| *Full Name | |
| Street Address | |
| City | |
| State | |
| Zip | |
| Dear $name, your Item $itemname has been succesfully added to the category $formtitle on $dltime . Wishing you a good sale. |
![]() |