Loading Please Wait!!

If you are not redirected to the auction site please Click here
#!/usr/bin/perl #!perl #!/usr/bin/perl5 #!/usr/local/bin/perl #!/usr/local/bin/perl5 ## Do not edit or delete these used command statements ## #-########################################################################### # Super-Bargins.Com Release Version v10 First release (5/24/2007) # This copyright notice MUST remain intact # Copyright (C) 2007 Super-Bargins.Com All rights reserved by the author. # http://www.super-bargins.com # # LICENSE AGREEMENT. # The following applies to the super-bargins.com compilation and any # portions of super-bargins.com it does not conflict with. Whenever this # policy does conflict with any individual portion of super-bargins.com, # it does not apply. In that event this source may not be redistributed or sold without # permission from super-bargins.com It may be modified for personal customization only, # By using this script, you are obligated to hold to these conditions, except as # regulated by local law. # # DISCLAIMER TERMS AND LIABILITY NOTICE: # 1) BY USING THIS CODE YOU AGREE TO INDEMNIFY SUPER-BARGINS.COM, AND ANY OF ITS EMPLOYEES, # FROM ANY LIABILITY THAT MIGHT ARISE FROM IT'S USE. SUPER-BARGINS.COM WILL NOT BE # RESPONSIBLE FOR ANY DAMAGES YOUR BUSINESS MAY SUFFER. USE THIS SCRIPT AT YOUR # OWN RISK WITH YOUR OWN SITE LIABILITY DISCLAIMERS. # # 2) WE NEITHER MAKE ANY WARRANTY NOR APPROVE THE MAKING OF ANY REPRESENTATION # THAT THE SOFTWARE WILL MEET YOUR REQUIREMENTS OR THAT THE OPERATION OF THE SOFTWARE # WILL BE UNINTERRUPTED OR ERROR FREE. YOU ARE RESPONSIBLE FOR ENSURING THAT THE # SOFTWARE WILL SATISFY YOUR REQUIREMENTS. # # 3) INSTALLATION/USE/MODIFICATION OF THIS SCRIPT IS AT YOUR OWN RISK! # USER ASSUMES ANY AND ALL LIABILITY WHILE INSTALLING/USING/MODIFYING THIS SCRIPT! # # 4) SUPER-BARGINS.COM RESERVES THE RIGHT TO AMEND OR UPDATE THESE POLICIES # WITHOUT NOTICE. # # IF YOU DO NOT AGREE TO THE ABOVE TERMS DO NOT USE THIS SCRIPT! # ############################################################################# use vars qw(%config %category %supercat %form %cookie $loginalias $loginpassword); use POSIX qw(strftime); use File::Copy; use strict; use CGI; use CGI::Carp qw(fatalsToBrowser); # on Windows NT/2000 servers only you need to specify # the drive letter (c:,d:,e:) with the server path to the config.pl file example: # require "c:/your/path/cgi-bin/auction/config.pl"; require "config.pl"; #-############################################# # Main Program # You do not need to edit anything below this # line. #-############################################# # Sub: Get Form Data # This gets data from a post. sub get_form_data { my $temp; my $buffer; my @data; read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'}); foreach $temp (split(/&|=/,$buffer)) { $temp =~ tr/+/ /; $temp =~ s/%([0-9a-fA-F]{2})/pack("c",hex($1))/ge; if ($temp !~ /\<(.+)\>/g) { $temp =~ s/\n/\/g; $temp =~ s/\s(?!\w+)/\ \;/g; } else { $temp =~ s/[\r\n]/ /g; } push @data, $temp; } foreach $temp (split(/&|=/,$ENV{'QUERY_STRING'})) { $temp =~ tr/+/ /; $temp =~ s/%([0-9a-fA-F]{2})/pack("c",hex($1))/ge; $temp =~ s/[\r\n]/ /g; push @data, $temp; } return @data; } #-############################################# # Sub: Pagebreak # This displays pagebreak links sub pagebreak { my $pagecnt = shift || 0; my $firstnumber = 0; my $lastnumber = $pagecnt; my $next = "Next Page >>"; my $previous = "<< Previous Page"; my $nonext = ""; my $noprevious = ""; my $totalcnt = ($pagecnt + 1); local $_; my $currentpage; ($currentpage = $form{'page'})++; if ($pagecnt > 10) { $firstnumber = ($currentpage - 6) if ($currentpage > 6); $lastnumber = ($currentpage + 4) if (($currentpage + 4) < $pagecnt); } my $action; foreach(keys %form){ next if($_ eq 'pb' || $_ eq 'page'); $action .= '&' if $action; $action .= "$_=$form{$_}"; } my($pagebreak) = @_; print "
"; ## Print Pagebreak Links ## if ($form{page} >= 1) { print " $previous "; } else { print " $noprevious "; } print "|" unless ($form{pb}); for ($firstnumber .. ($form{'page'} - 1)) { print " @{[$_+1]} "; } print " $currentpage " unless ($form{pb}); print " All Items " if ($form{pb}); for (($form{'page'} + 1) .. $lastnumber) { print " @{[$_+1]} "; } print " of $totalcnt " unless ($form{pb}); if ($form{pb}) { print " Back "; } print "|" unless ($form{pb}); if ($form{page} < $pagecnt) { print " $next "; } else { print " $nonext "; } ## END Print Pagebreak Links ## print "
"; } #-############################################# # Sub: Backto # Provides the category path for the # supercat add-on. sub backto{ my $Separator = " > "; my $Item = "Item"; my $Home = ""; my (@backs, $backto, $path, $thispath, $current); if($_[0] eq ''){$_[0] = $form{category}} $thispath=$_[0]; if($category{$_[0]} ne ''){ $thispath=$category{$form{category}}; while($thispath=~s/^//){ if($supercat{$1} ne ''){$thispath.=":$1"} } # $current=$category{$_[0]};## } @backs=split(/\:/, $thispath); foreach (0..($#backs-1)){ if($supercat{$backs[$_]} ne ''){ $path.=":$backs[$_]"; $backto.="$Separator$supercat{$backs[$_]}"; } } $path.=":$backs[-1]"; if($supercat{$backs[-1]} ne '' && $category{$_[0]} ne ''){ if($form{item} ne ''){ # ITEM $backto.="$Separator$supercat{$backs[-1]}$Separator$category{$_[0]}$Separator$Item"; } else { # ITEMLIST $backto.="$Separator$supercat{$backs[-1]}$Separator$category{$_[0]}"; } }elsif($supercat{$backs[-1]} ne ''){ # SUBCATEGORIES $backto.="$Separator$supercat{$backs[-1]}"; } if($backto ne ''){return "$Home$backto"} else{return ''} } #-############################################# # Sub: Display List Of Items # This creates a "nice" list of items in a # category. sub displist { my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); ### 24 Hr clock ###### #my $nowtime = localtime(time + ($config{'systemtime'}* 3600 )); my $backto = &backto; print "

All Files Listed in Category $category{$form{'category'}}:

"; my $numfiles = scalar @{[readdir THEDIR]}; closedir THEDIR; print "
Sort Listings By:  Items Ending First  |  Newly-Listed First  |  Lowest Prices First  |  Highest Prices First

"; #-###### Category Featured Auctions ############### print "
BuyItNow | New | Picture | Hot | Ending | Dutch | Reserve Price | Reserve Price Met
"; print "
Gallery | "; print "Featured | "; print "New | "; print "Hot | "; print "Closing Today | "; print "3 Hours Left | "; print "Dutch Items"; print "
"; print ""; print "\n"; print "
Featured Listings In $backto
"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); my @allfeatfiles = (); my @sortedfiles = &sort_items; readdir THEDIR; closedir THEDIR; my $element; foreach $element (@sortedfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfeatfiles, $element); } my $rowcount1 = 0; my $featfile; foreach $featfile (@allfeatfiles) { $featfile =~ s/^$config{'basepath'}$form{'category'}\///; $featfile =~ s/\.dat$//; open FILE, "$config{'basepath'}$form{'category'}/$featfile.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); # read last bid #### Added for NEW items. my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); # read first bid ###### Read the feature Array from the item file ###### my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($featfile); if ($feat_cp eq "YES"){ my $itemrowcolor1; if ($rowcount1 % 2 == 1) { $itemrowcolor1=$config{'colorevenrow'} } else { $itemrowcolor1=$config{'coloroddrow'} } $rowcount1++; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($featfile < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } print "
Item Name
#Bids
High Bid
Ends In
$filler$imagedisp
$config{'displistfont'} $grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
"; # #-###### End Category Featured Auctions ############### # print "

\ \;

"; #-###### Standard Item Category List ############### print "
BuyItNow | New | Picture | Hot | Ending | Dutch | Reserve Price | Reserve Price Met
"; print "
Gallery | "; print "Featured | "; print "New | "; print "Hot | "; print "Closing Today | "; print "3 Hours Left | "; print "Dutch Items"; print "
"; print "\n"; print ""; print "
Standard Listings In $backto
"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); my @allfiles = (); my @sortedfiles = &sort_items; readdir THEDIR; closedir THEDIR; my $element; foreach $element (@sortedfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfiles, $element); } my $rowcount2 = 0; ##### Page Break my $pagebreak = int $form{pb} || 20; my ($icount, $pcount) = (0,0); my $file; foreach $file (@allfiles) { ##### End Page Break $file =~ s/^$config{'basepath'}$form{'category'}\///; $file =~ s/\.dat$//; open FILE, "$config{'basepath'}$form{'category'}/$file.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); #### Added for NEW items. my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($file); if (($feat_cp eq "NO") && ($#bids < $config{'hotnum'})) { if(++$icount > $pagebreak){$icount=1; $pcount++} next if $pcount != $form{page}; my $itemrowcolor2; if ($rowcount2 % 2 == 1) { $itemrowcolor2=$config{'colorevenrow'} } else { $itemrowcolor2=$config{'coloroddrow'} } $rowcount2++; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($file < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } if ($icount <= 0){ print ""; } print "
Item Name
#Bids
High Bid
Ends In
$filler$imagedisp
$config{'displistfont'} $grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
No Items to View
"; ### Page Break &pagebreak($pcount,$pagebreak); print "

\ \;

"; #-###### Hot Items Category List ############### print "
BuyItNow | New | Picture | Hot | Ending | Dutch | Reserve Price | Reserve Price Met
"; print "
Gallery | "; print "Featured | "; print "New | "; print "Hot | "; print "Closing Today | "; print "3 Hours Left | "; print "Dutch Items"; print "
"; print ""; print ""; print "
Hot Items In $backto
"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); my @allhotfiles = (); my @sortedfiles = &sort_items; readdir THEDIR; closedir THEDIR; my $element; foreach $element (@sortedfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allhotfiles, $element); } my $rowcount3 = 0; my $hotfile; foreach $hotfile (@allhotfiles) { $hotfile =~ s/^$config{'basepath'}$form{'category'}\///; $hotfile =~ s/\.dat$//; open FILE, "$config{'basepath'}$form{'category'}/$hotfile.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); # read last bid #### Added for NEW items. my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); # read first bid ###### Read the feature Array from the item file ###### my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($hotfile); if ($#bids >= $config{'hotnum'}){ my $itemrowcolor3; if ($rowcount3 % 2 == 1) { $itemrowcolor3 = $config{'colorevenrow'}; } else { $itemrowcolor3 = $config{'coloroddrow'}; } $rowcount3++; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($hotfile < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } if ($icount <= 0){ print ""; } print "
Item Name
#Bids
High Bid
Ends In
$filler$imagedisp
$config{'displistfont'} $grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
No Items to View
"; print "

\ \;

"; } ##################################################### sub sort_items { my @sortedfiles; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); if (!defined($form{'sort'}) || $form{'sort'} eq 'closes') { @sortedfiles = ( grep -T, map "$config{'basepath'}$form{'category'}/$_", sort { int($main::a) <=> int($main::b) } (readdir THEDIR) ); } else { my @allfiles; @allfiles = readdir THEDIR; my $file; my %pairs; foreach $file (@allfiles) { if (-T "$config{'basepath'}$form{'category'}/$file") { open THEFILE, "$config{'basepath'}$form{'category'}/$file"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close THEFILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); if ($form{'sort'} eq 'starts') { my @firstbid = split(/\[\]/,$bids[$#bids]); $pairs{$file} = $firstbid[3]; } elsif ($form{'sort'} eq 'lowbid') { my @lastbid = split(/\[\]/,$bids[$#bids]); $pairs{$file} = $lastbid[2]; } elsif ($form{'sort'} eq 'highbid') { my @lastbid = split(/\[\]/,$bids[$#bids]); $pairs{$file} = $lastbid[2]; } } } closedir THEDIR; if ($form{'sort'} eq 'starts') { @sortedfiles = sort {$pairs{$main::b} <=> $pairs{$main::a} || ($main::a <=> $main::b) } (keys(%pairs)); } elsif ($form{'sort'} eq 'highbid') { @sortedfiles = sort { ((($pairs{$main::b}) <=> ($pairs{$main::a})) || ($main::a <=> $main::b)) } (keys(%pairs)); } elsif ($form{'sort'} eq 'lowbid') { @sortedfiles = sort { ((($pairs{$main::a}) <=> ($pairs{$main::b})) || ($main::a <=> $main::b)) } (keys(%pairs)); } } return @sortedfiles; } #-############################################# # Sub: Display List Of Gallery Items # This creates a "nice" list of items in a # category. sub displistgal { my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); print "

Gallery Featured Items in Category $category{$form{'category'}}:

\n"; print "

Current Time: $nowtime $config{'timezone'}
"; print " Gallery |"; print " Featured |"; print " New |"; print " Hot |"; print " Closing Today |"; print " 3 Hours Left |"; print " Dutch Items |"; print "

"; print "
"; my $s = 1; my $pagebreak = int $form{pb} || 24; my ($icount, $pcount) = (0,0); opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); #readdir THEDIR; #readdir THEDIR; #my @allfiles = sort { $a <=> $b } map {int $_} readdir THEDIR; #closedir THEDIR; # July 8, 2006 my @allfiles = (); my @tmpfiles = sort { $a <=> $b } readdir THEDIR; closedir THEDIR; my $element; foreach $element (@tmpfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfiles, $element); } my $file; foreach $file (@allfiles) { $file =~ s/^$config{'basepath'}$form{'category'}\///; $file =~ s/\.dat$//; open FILE, "$config{'basepath'}$form{'category'}/$file.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($file); my $image = ""; if ($gallery eq "Yes") { if(++$icount > $pagebreak){$icount=1; $pcount++} next if $pcount != $form{page}; print "" if ($image); if ($s==4) { print ""; $s = 1; } else { $s++; } } } if ($icount <= 0){ print ""; } if ($s > 1 && $s < 4) { print ""; } print "

Featured Picture GALLERY (Click on an image for more details)

$image
$title
Current Bid: $config{'currencytype'}$bid
Number of Bids: $#bids
Closes: $timeremain
No Gallery Items to View
"; print "
"; &pagebreak($pcount,$pagebreak); } #-############################################# # Sub: Display List Of Featured Items # This creates a "nice" list of items in a # category. sub displistfeat { my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); print "

Featured Items in Category $category{$form{'category'}}:

\n"; print "

Current Time: $nowtime $config{'timezone'}
"; print " Featured |"; print " Gallery |"; print " New |"; print " Hot |"; print " Closing Today |"; print " 3 Hours Left |"; print " Dutch Items |"; print "

"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); #readdir THEDIR; #readdir THEDIR; #my @allfiles = sort { $a <=> $b } map {int $_} readdir THEDIR; #closedir THEDIR; # July 8, 2006 my @allfiles = (); my @tmpfiles = sort { $a <=> $b } readdir THEDIR; closedir THEDIR; my $element; foreach $element (@tmpfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfiles, $element); } my $file; my $rowcount = 0; ##### Page Break my $pagebreak = int $form{pb} || 30; my ($icount, $pcount) = (0,0); foreach $file (@allfiles) { ##### End Page Break $file =~ s/^$config{'basepath'}$form{'category'}\///; $file =~ s/\.dat$//; my $itemrowcolor; if ($rowcount % 2 == 1) { $itemrowcolor=$config{'colorevenrow'}; } else { $itemrowcolor=$config{'coloroddrow'}; } open FILE, "$config{'basepath'}$form{'category'}/$file.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($file); if ($feat_fp eq "YES"){ $rowcount++; if(++$icount > $pagebreak){$icount=1; $pcount++} next if $pcount != $form{page}; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($file < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } if ($icount <= 0){ print ""; } print "
Item Name
#Bids
High Bid
Closes
$filler$imagedisp
$config{'displistfont'}$grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
No Items to View
"; ### Page Break &pagebreak($pcount,$pagebreak); } #-############################################# # Sub: Display List Of NEW Items # This creates a "nice" list of items in a # category. sub displistnew { my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); print "

New Items in Category $category{$form{'category'}}:

\n"; print "

Current Time: $nowtime $config{'timezone'}
"; print " New |"; print " Gallery |"; print " Featured |"; print " Hot |"; print " Closing Today |"; print " 3 Hours Left |"; print " Dutch Items |"; print "

"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); #readdir THEDIR; #readdir THEDIR; #my @allfiles = sort { $a <=> $b } map {int $_} readdir THEDIR; #closedir THEDIR; # July 8, 2006 my @allfiles = (); my @tmpfiles = sort { $a <=> $b } readdir THEDIR; closedir THEDIR; my $element; foreach $element (@tmpfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfiles, $element); } my $file; my $rowcount = 0; ##### Page Break my $pagebreak = int $form{pb} || 30; my ($icount, $pcount) = (0,0); foreach $file (@allfiles) { ##### End Page Break $file =~ s/^$config{'basepath'}$form{'category'}\///; $file =~ s/\.dat$//; my $itemrowcolor; if ($rowcount % 2 == 1) { $itemrowcolor=$config{'colorevenrow'}; } else { $itemrowcolor=$config{'coloroddrow'}; } open FILE, "$config{'basepath'}$form{'category'}/$file.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($file); if (($sellertime + (86400 * $config{'newdays'})) > time){ $rowcount++; if(++$icount > $pagebreak){$icount=1; $pcount++} next if $pcount != $form{page}; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($file < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } if ($icount <= 0){ print ""; } print "
Item Name
#Bids
High Bid
Closes
$filler$imagedisp
$config{'displistfont'}$grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
No Items to View
"; ### Page Break &pagebreak($pcount,$pagebreak); } #-############################################# # Sub: Display List Of HOT Items # This creates a "nice" list of items in a # category. sub displisthot { my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); print "

Hot Items in Category $category{$form{'category'}}:

\n"; print "

Current Time: $nowtime $config{'timezone'}
"; print " Hot |"; print " Gallery |"; print " Featured |"; print " New |"; print " Closing Today |"; print " 3 Hours Left |"; print " Dutch Items |"; print "

"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); #readdir THEDIR; #readdir THEDIR; #my @allfiles = sort { $a <=> $b } map {int $_} readdir THEDIR; #closedir THEDIR; # July 8, 2006 my @allfiles = (); my @tmpfiles = sort { $a <=> $b } readdir THEDIR; closedir THEDIR; my $element; foreach $element (@tmpfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfiles, $element); } my $file; my $rowcount = 0; ##### Page Break my $pagebreak = int $form{pb} || 30; my ($icount, $pcount) = (0,0); foreach $file (@allfiles) { ##### End Page Break $file =~ s/^$config{'basepath'}$form{'category'}\///; $file =~ s/\.dat$//; my $itemrowcolor; if ($rowcount % 2 == 1) { $itemrowcolor=$config{'colorevenrow'}; } else { $itemrowcolor=$config{'coloroddrow'}; } open FILE, "$config{'basepath'}$form{'category'}/$file.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($file); if ($#bids >= $config{'hotnum'}){ $rowcount++; if(++$icount > $pagebreak){$icount=1; $pcount++} next if $pcount != $form{page}; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($file < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } if ($icount <= 0){ print ""; } print "
Item Name
#Bids
High Bid
Closes
$filler$imagedisp
$config{'displistfont'}$grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
No Items to View
"; ### Page Break &pagebreak($pcount,$pagebreak); } #-############################################# # Sub: Display List Of Going Items in 3 hrs # This creates a "nice" list of items in a # category. sub displistgone { my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); print "

Closing Items in 3Hrs in Category $category{$form{'category'}}:

\n"; print "

Current Time: $nowtime $config{'timezone'}
"; print " 3 Hours Left |"; print " Gallery |"; print " Featured |"; print " New |"; print " Hot |"; print " Closing Today |"; print " Dutch Items |"; print "

"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); #readdir THEDIR; #readdir THEDIR; #my @allfiles = sort { $a <=> $b } map {int $_} readdir THEDIR; #closedir THEDIR; # July 8, 2006 my @allfiles = (); my @tmpfiles = sort { $a <=> $b } readdir THEDIR; closedir THEDIR; my $element; foreach $element (@tmpfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfiles, $element); } my $file; my $rowcount = 0; ##### Page Break my $pagebreak = int $form{pb} || 30; my ($icount, $pcount) = (0,0); foreach $file (@allfiles) { ##### End Page Break $file =~ s/^$config{'basepath'}$form{'category'}\///; $file =~ s/\.dat$//; my $itemrowcolor; if ($rowcount % 2 == 1) { $itemrowcolor=$config{'colorevenrow'}; } else { $itemrowcolor=$config{'coloroddrow'}; } open FILE, "$config{'basepath'}$form{'category'}/$file.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($file); if ($file < (time + (3600 * $config{'goinghours'}))){ $rowcount++; if(++$icount > $pagebreak){$icount=1; $pcount++} next if $pcount != $form{page}; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($file < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } if ($icount <= 0){ print ""; } print "
Item Name
#Bids
High Bid
Closes
$filler$imagedisp
$config{'displistfont'}$grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
No Items to View
"; ### Page Break &pagebreak($pcount,$pagebreak); } #-############################################# # Sub: Display List Of Items Closing Today # This creates a "nice" list of items in a # category. sub displistclose { my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); print "

Closing Today Items in Category $category{$form{'category'}}:

\n"; print "

Current Time: $nowtime $config{'timezone'}
"; print " Closing Today |"; print " Gallery |"; print " Featured |"; print " New |"; print " Hot |"; print " 3 Hours Left |"; print " Dutch Items |"; print "

"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); #readdir THEDIR; #readdir THEDIR; #my @allfiles = sort { $a <=> $b } map {int $_} readdir THEDIR; #closedir THEDIR; # July 8, 2006 my @allfiles = (); my @tmpfiles = sort { $a <=> $b } readdir THEDIR; closedir THEDIR; my $element; foreach $element (@tmpfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfiles, $element); } my $file; my $rowcount = 0; ##### Page Break my $pagebreak = int $form{pb} || 30; my ($icount, $pcount) = (0,0); foreach $file (@allfiles) { ##### End Page Break $file =~ s/^$config{'basepath'}$form{'category'}\///; $file =~ s/\.dat$//; my $itemrowcolor; if ($rowcount % 2 == 1) { $itemrowcolor=$config{'colorevenrow'}; } else { $itemrowcolor=$config{'coloroddrow'}; } open FILE, "$config{'basepath'}$form{'category'}/$file.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($file); if ($file < (time + 86400)) { $rowcount++; if(++$icount > $pagebreak){$icount=1; $pcount++} next if $pcount != $form{page}; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($file < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } if ($icount <= 0){ print ""; } print "
Item Name
#Bids
High Bid
Closes
$filler$imagedisp
$config{'displistfont'}$grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
No Items to View
"; ### Page Break &pagebreak($pcount,$pagebreak); } #-############################################# # Sub: Display List Of Dutch Items # This creates a "nice" list of items in a # category. sub displistdutch { my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); print "

Dutch Items in Category $category{$form{'category'}}:

\n"; print "

Current Time: $nowtime $config{'timezone'}
"; print " Dutch |"; print " Gallery |"; print " Featured |"; print " New |"; print " Hot |"; print " Closing Today |"; print " 3 Hours Left |"; print "

"; print ""; print ""; opendir THEDIR, "$config{'basepath'}$form{'category'}" or &oops("Category directory $form{'category'} could not be opened."); #readdir THEDIR; #readdir THEDIR; #my @allfiles = sort { $a <=> $b } map {int $_} readdir THEDIR; #closedir THEDIR; # July 8, 2006 my @allfiles = (); my @tmpfiles = sort { $a <=> $b } readdir THEDIR; closedir THEDIR; my $element; foreach $element (@tmpfiles) { next unless ($element ne '_vti_cnf' && $element ne '.' && $element ne '..'); push (@allfiles, $element); } my $file; my $rowcount = 0; ##### Page Break my $pagebreak = int $form{pb} || 30; my ($icount, $pcount) = (0,0); foreach $file (@allfiles) { ##### End Page Break $file =~ s/^$config{'basepath'}$form{'category'}\///; $file =~ s/\.dat$//; my $itemrowcolor; if ($rowcount % 2 == 1) { $itemrowcolor=$config{'colorevenrow'}; } else { $itemrowcolor=$config{'coloroddrow'}; } open FILE, "$config{'basepath'}$form{'category'}/$file.dat"; my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = ; close FILE; chomp($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); my ($selleralias, $selleremail, $sellerbid, $sellertime, $selleradd1, $selleradd2, $selleradd3) = &read_bid($bids[0]); my ($feat_fp, $feat_cp, $feat_yt, $feat_bf) = &read_feature($feature); #read features my $timeremain = time_remain($file); if (($dutch) eq ('yes')) { $rowcount++; if(++$icount > $pagebreak){$icount=1; $pcount++} next if $pcount != $form{page}; my $filler = ""; my $new = "" if (($sellertime + (86400 * $config{'newdays'})) > time); my $image = "" if ($image1); my $hot = "" if ($#bids >= $config{'hotnum'}); my $end = "" if ($file < (time + $config{'endhours'} * 86400)); my $dutchicon = "" if ($dutch eq 'yes'); my $buyitnow = "" if (($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0') or ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $bid)); my $reserveprice = "" if ($reserve > '0.00') && ($reserve > $bid) && ($dutch eq 'no'); my $reservepricemet = "" if ($bid >= $reserve) && ($reserve > '0.00') && ($dutch eq 'no'); my $imagedisp = "" if (($image1 ne "")); my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $mytitle; if ($feat_yt eq "YES"){ print ""; } else { print ""; } if ($feat_bf eq "YES") { $mytitle = "$title"; } else { $mytitle = "$title"; } print ""; print ""; print "\n"; } } if ($icount <= 0){ print ""; } print "
Item Name
#Bids
High Bid
Closes
$filler$imagedisp
$config{'displistfont'}$grabberpic $mytitle $buyitnow $new $hot $end $dutchicon $reserveprice $reservepricemet"; if ($subtitle) { print "
      $subtitle"; } print "
$#bids
$config{'currencytype'}$bid
$timeremain
No Items to View
"; ### Page Break &pagebreak($pcount,$pagebreak); } #-############################################# # Sub: Display Item # This displays a particular item, its # description, and its associated bids. sub dispitem { my ($loginalias, $loginpassword) = setlogin(); $loginalias = ucfirst lc $loginalias; my($password, $undef) = &read_reg_file($loginalias); if(lc $password ne lc $loginpassword || $password eq ''){ $loginalias = $loginpassword = '' } my ($title, $subtitle, $reserve, $inc, $desctitcolor, $desctitsize, $desctit, $desccolor, $descsize, $desc, $image1, $image2, $image3, $image4, $feature, $grabber, $dutch, $qty, $payment, $condition, $shipping, $shippingcost, $relist, $relistcnt, $gallery, $buyit, $music, $usecounter, @bids) = &read_item_file($form{'category'},$form{'item'}); &oops("This item is now closed. You can view this item and bid history using the All Closed Auctions link then by selecting the item number in question. If you were the seller or the winning bidder, you can use the View Your Closed Won/Sold link from site links menu to view your closed auction items won or sold.") unless ($title); my ($highbidder, $reservemsg, $sellerpage, $sellersstore, $bidderpage, $buyitnow); my $backto = &backto; my $nowtime = strftime "%a %b %d, %I:%M %p", gmtime(time + ($config{'systemtime'}* 3600 )); my $closetime = strftime "%a %b %d, %I:%M %p", gmtime($form{item} + ($config{'systemtime'}* 3600 )); my ($selleralias, $selleremail, $bid, $sellertime, $selleradd1, $selleradd2, $selleradd3, $selleroqty, $sellersoldqty) = &read_bid($bids[0]); # read first bid my $bidstart = strftime "%a %b %d, %I:%M %p", gmtime($sellertime + ($config{'systemtime'}* 3600 )); my $numbids = $#bids; my $firstbid = $bid; my $sellername = $selleradd1; my $location = $selleradd2; my $location2 = $selleradd3; my ($alias, $email, $lastbid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$numbids]); # read last bid ### use commas in the bid price ### if ($config{'currencylayout'} eq 'yes') { $firstbid =~ s/\G(\d{1,3})(?=(?:\d\d\d)+(?:\.|$))/$1,/g; $lastbid =~ s/\G(\d{1,3})(?=(?:\d\d\d)+(?:\.|$))/$1,/g; } my $timeremain; if ((time > int($form{'item'})) && (time < (60 * $config{'aftermin'} + $time))) { $timeremain = "Extended over time bidding"; } else { $timeremain = time_remain($form{item}); } my $sold; if (($dutch eq 'yes') && ($soldqty eq "")) { $sold = "- Number Sold: 0"; } if (($dutch eq 'yes') && ($soldqty ne "")) { $sold = "- Number Sold: $soldqty"; } if ($dutch eq 'no') { $sold = ""; } $reservemsg = ""; $reservemsg = "Reserve Not Met" if (($lastbid < $reserve) && ($dutch eq 'no')); $reservemsg = "Reserve Met" if (($lastbid >= $reserve) && ($reserve > 0) && ($dutch eq 'no')); $reservemsg = "No Reserve " if (($reserve <= 0) && ($dutch eq 'no')); $reservemsg = "Dutch Fixed Price " if ($dutch eq 'yes'); open (FEEDFILE, "$config{'feeddir'}/$selleralias.dat"); my ($spositive, $sneutral, $snegative, @suserfeeds) = ; close FEEDFILE; chomp($spositive, $sneutral, $snegative, @suserfeeds); my $sellerrating = $spositive - $snegative; my $sellervotes = $spositive + $sneutral + $snegative; my $totalper = ($spositive + $sneutral + $snegative); my $per = sprintf("%.1f", (($spositive/$totalper)*100)) if ($spositive && $totalper); my $percent = "$per\%" if ($per); $percent = "Rating 0\%" if ($per eq ""); my $star1s = "\"1-49\"" if ($sellerrating >= '1'); my $star2s = "\"50-99\"" if ($sellerrating >= '50'); my $star3s = "\"100-499\"" if ($sellerrating >= '100'); my $star4s = "\"500-999\"" if ($sellerrating >= '500'); my $star5s = "\"1000-5000\"" if ($sellerrating >= '1000'); open (FEEDFILE, "$config{'feeddir'}/$alias.dat"); my ($bpositive, $bneutral, $bnegative, @buserfeeds) = ; close FEEDFILE; chomp($bpositive, $bneutral, $bnegative, @buserfeeds); my $bidderrating = $bpositive - $bnegative; my $biddervotes = $bpositive + $bneutral + $bnegative; my $star1b = "\"1-49\"" if ($bidderrating >= '1'); my $star2b = "\"50-99\"" if ($bidderrating >= '50'); my $star3b = "\"100-499\"" if ($bidderrating >= '100'); my $star4b = "\"500-999\"" if ($bidderrating >= '500'); my $star5b = "\"1000-5000\"" if ($bidderrating >= '1000'); if ($alias eq $selleralias){ $highbidder = "No bids yet"; } else { $highbidder = "$alias (bidders's feedback:( $bidderrating ) $star1b $star2b $star3b $star4b $star5b) - (bidders auctions)"; } if (-f "$config{'basepath'}$config{'mystoredir'}/$selleralias.st") { $sellersstore =" View sellers store front"; } else { print ""; } if (-f "$config{'basepath'}$config{'mypagedir'}/$selleralias.me") { $sellerpage =" - (View My Page)"; } else { print ""; } if (($#bids) && (-f "$config{'basepath'}$config{'mypagedir'}/$alias.me")) { $bidderpage =" - (View My Page)"; } else { print ""; } my $grabberpic = ""; $grabberpic = "" if ($grabber eq "grab1"); $grabberpic = "" if ($grabber eq "grab2"); $grabberpic = "" if ($grabber eq "grab3"); $grabberpic = "" if ($grabber eq "grab4"); $grabberpic = "" if ($grabber eq "grab5"); $grabberpic = "" if ($grabber eq "grab6"); $grabberpic = "" if ($grabber eq "grab7"); $grabberpic = "" if ($grabber eq "grab8"); my $bgmusic = ""; $bgmusic = "$config{'music1'}" if ($music eq "music1"); $bgmusic = "$config{'music2'}" if ($music eq "music2"); $bgmusic = "$config{'music3'}" if ($music eq "music3"); $bgmusic = "$config{'music4'}" if ($music eq "music4"); $bgmusic = "$config{'music5'}" if ($music eq "music5"); $bgmusic = "$config{'music6'}" if ($music eq "music6"); $bgmusic = "$config{'music7'}" if ($music eq "music7"); $bgmusic = "$config{'music8'}" if ($music eq "music8"); if ($config{'backgroungmusic'} eq 'yes') { print <<"EOF"; EOF } print <<"EOF";
Back to previous page
Listed in category: $backto  
$title EOF if ($subtitle) { print <<"EOF";  -  $subtitle EOF } print <<"EOF";
 - $config{'timezone'}
Watch this listing: Item #$form{'item'} 
EOF if (($config{'buyitnow'} eq 'yes') && ($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0')) { print <<"EOF";
Buy Now For: $config{'currencytype'}$buyit
This option will disappear once a bid is placed.
EOF } if (($config{'buyitnow'} eq 'yes') && ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $lastbid)) { print <<"EOF";
Buy Now For: $config{'currencytype'}$buyit
This option disappears once the reserve price has been met.
EOF } print <<"EOF";
EOF if ($image1 ne "") { print <<"EOF";
Show picture

View description image

EOF } print <<"EOF";
Current Bid: $config{'currencytype1'} $config{'currencytype'}$lastbid  ( $reservemsg )
Ending time: $closetime ($timeremain)
Starting time: $bidstart
Shipping terms: $shipping
EOF if ($shippingcost eq "0.00") { print <<"EOF";
Shipping costs: Check item description and payment instructions or contact seller for details
EOF } else { print <<"EOF";
Shipping costs: $config{'currencytype'}$shippingcost
EOF } print <<"EOF";
Item location: $location2
Bid history: $#bids bids
Quantity: $qty $sold
Payment options: $payment
Meet the seller
Seller: $selleralias ( $sellerrating ) $star1s $star2s $star3s $star4s $star5s $percent
Ask the seller a question
eMail this item to a friend
View sellers other auctions
EOF if (-f "$config{'basepath'}$config{'mystoredir'}/$selleralias.st") { print <<"EOF";
$sellersstore
EOF } print <<"EOF";
Buyer: Retract your bid(s)
Report this item
Seller ban a bidder
Seller revise your item
  Item Description - Condition of Item:  $condition )

$desctitcolor$desctitsize
$desctit
$desccolor$descsize
$desc
EOF if ($image1) { print <<"EOF";
EOF } if ($image2) { print <<"EOF";
Click Thumbnails Below For Larger Picture Above
EOF } if ($image2) { print <<"EOF"; EOF } if ($image1) { print <<"EOF"; EOF } if ($usecounter eq "Yes") { open(READCOUNT,"$config{'basepath'}$config{'countdir'}/$form{'item'}.dat"); my $totalReads = ; chomp $totalReads; close(READCOUNT); $totalReads++; open(COUNT,">$config{'basepath'}$config{'countdir'}/$form{'item'}.dat"); if ($config{'flock'}) { flock(COUNT, 2); seek(COUNT, 0, 2); } print (COUNT "$totalReads\n"); flock(COUNT, 8); close(COUNT); print <<"EOF";
EOF } if ($image2) { print <<"EOF"; EOF } if ($image3) { print <<"EOF"; EOF } if ($image4) { print <<"EOF";
This Item has been viewed ( $totalReads ) times.
EOF } ## End Bid History ###################### # either the item is closed or we will display a bid form if ((time > int($form{'item'})) && (time > (60 * $config{'aftermin'} + $time))) { print "BIDDING IS NOW CLOSED
"; } else { ##### Normal Bid Form if ($dutch eq 'no') { my $closetime = localtime($form{'item'}); my ($alias, $email, $bid, $time, $add1, $add2, $add3, $oqty, $soldqty) = &read_bid($bids[$#bids]); # read the last bid my $lowest_new_bid; $lowest_new_bid = (&read_bid($bids[0]))[2]; $lowest_new_bid = &parsebid($bid); $lowest_new_bid = &parsebid($bid + $inc) if ($#bids); ### use commas in the bid price ### print <<"EOF";
  Place A Bid
$title
Item: #$form{'item'}
EOF if (($config{'buyitnow'} eq 'yes') && ($buyit > '0') && ($#bids eq '0') && ($dutch eq 'no') && ($reserve <= '0')) { print <<"EOF";
Buy Now For: $config{'currencytype'}$buyit
This option will disappear once a bid is placed.
EOF } if (($config{'buyitnow'} eq 'yes') && ($buyit > '0') && ($dutch eq 'no') && ($reserve > '0') && ($reserve > $lastbid)) { print <<"EOF";
Buy Now
For: $config{'currencytype'}$buyit
This option disappears
once the reserve price has been met.
EOF } print <<"EOF";

EOF print <<"EOF"; Number of bids: $#bids
The High Bid Is: $config{'currencytype'}$bid
The Lowest You May Bid Is: $config{'currencytype'}$lowest_new_bid


EOF if ($config{'regdir'}) { print <<"EOF";

You must be a registered user to place a bid
Your Username:
Your Password:

Your Maximum Bid: $config{'currencytype'}

EOF } else { print <<"EOF";

Your Username: (used to track your bid)
Your E-Mail Address: (must be valid)
Your Bid: $config{'currencytype'}

Contact Information: (will be given out only to the seller)
Full Name:

Street Address:

City, State, ZIP:

EOF } print <<"EOF";

How to Bid
  • Register to bid
    It's free, and required to bid, buy or sell.
  • Know the item
    Read the full description of the item you are bidding on.
  • Ask the seller a question
    If you have questions about the item before you place a bid.
  • Please bid the maximum amount you are willing to pay for this item. Your maximum amount will be kept secret; $config{'sitename'} will bid on your behalf as necessary by increasing your bid by the current bid increment up until your maximum is reached. This saves you the trouble