";
$connid = mysql_connect ('localhost' , 'rastrono' , 'sinhosejar');
mysql_select_db ("rastrono_numbers");
for ($opeecheeyears=65;$opeecheeyears<93;$opeecheeyears++) {
$toppsquery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$opeecheeyears." Topps #%'";
$opeecheequery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$opeecheeyears." O-Pee-Chee #%'";
$topps=mysql_query($toppsquery);
$opeechee=mysql_query($opeecheequery);
while($row = mysql_fetch_array($topps)){
$toppses = $row[COUNT('fullname')];}
while($row2 = mysql_fetch_array($opeechee)){
$opeecheeses = $row2[COUNT('fullname')];
}
if ($toppses == $opeecheeses){
$equalitycounter++;
if ($equalitycounter<10) {$spacer=" ";}
if ($equalitycounter>9 && $equalitycounter<100) {$spacer=" ";}
if ($equalitycounter>99) {$spacer="";}
if ($equalitycounter%2==1) {$stylephrase="style=\"background-color:beige\"";} else {$stylephrase="";}
echo "".$spacer;
echo $equalitycounter.". 19".$opeecheeyears." O-Pee-Chee";
echo " (".$toppses.") | -- | \r\n";
} //end if
} //end for next
for ($toppstiffanyyears=84;$toppstiffanyyears<92;$toppstiffanyyears++) {
$toppsquery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$toppstiffanyyears." Topps #%'";
$toppstiffanyquery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$toppstiffanyyears." Topps Tiffany #%'";
$topps=mysql_query($toppsquery);
$toppstiffany=mysql_query($toppstiffanyquery);
while($row = mysql_fetch_array($topps)){
$toppses = $row[COUNT('fullname')];}
while($row2 = mysql_fetch_array($toppstiffany)){
$toppstiffanyses = $row2[COUNT('fullname')];
}
if ($toppses == $toppstiffanyses){
$equalitycounter++;
if ($equalitycounter<10) {$spacer=" ";}
if ($equalitycounter>9 && $equalitycounter<100) {$spacer=" ";}
if ($equalitycounter>99) {$spacer="";}
if ($equalitycounter%2==1) {$stylephrase="style=\"background-color:beige\"";} else {$stylephrase="";}
echo "".$spacer;
echo $equalitycounter.". 19".$toppstiffanyyears." Topps Tiffany";
echo " (".$toppses.") | -- |
\r\n";
} //end if
} //end for next
for ($toppstradedtiffanyyears=84;$toppstradedtiffanyyears<92;$toppstradedtiffanyyears++) {
$toppstradedquery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$toppstradedtiffanyyears." Topps Traded #%'";
$toppstradedtiffanyquery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$toppstradedtiffanyyears." Topps Traded Tiffany #%'";
$toppstraded=mysql_query($toppstradedquery);
$toppstradedtiffany=mysql_query($toppstradedtiffanyquery);
while($row = mysql_fetch_array($toppstraded)){
$toppstradedes = $row[COUNT('fullname')];}
while($row2 = mysql_fetch_array($toppstradedtiffany)){
$toppstradedtiffanyses = $row2[COUNT('fullname')];
}
if ($toppstradedes == $toppstradedtiffanyses){
$equalitycounter++;
if ($equalitycounter<10) {$spacer=" ";}
if ($equalitycounter>9 && $equalitycounter<100) {$spacer=" ";}
if ($equalitycounter>99) {$spacer="";}
if ($equalitycounter%2==1) {$stylephrase="style=\"background-color:beige\"";} else {$stylephrase="";}
echo "".$spacer;
echo $equalitycounter.". 19".$toppstradedtiffanyyears." Topps Traded Tiffany";
echo " (".$toppstradedes.") | -- |
\r\n";
} //end if
} //end for next
for ($fleertiffanyyears=96;$fleertiffanyyears<98;$fleertiffanyyears++) {
$fleerquery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$fleertiffanyyears." Fleer #%'";
$fleertiffanyquery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$fleertiffanyyears." Fleer Tiffany #%'";
$fleers=mysql_query($fleerquery);
$fleertiffany=mysql_query($fleertiffanyquery);
while($row = mysql_fetch_array($fleers)){
$fleerses = $row[COUNT('fullname')];}
while($row2 = mysql_fetch_array($fleertiffany)){
$fleertiffanyses = $row2[COUNT('fullname')];
}
if ($fleerses == $fleertiffanyses){
$equalitycounter++;
if ($equalitycounter<10) {$spacer=" ";}
if ($equalitycounter>9 && $equalitycounter<100) {$spacer=" ";}
if ($equalitycounter>99) {$spacer="";}
if ($equalitycounter%2==1) {$stylephrase="style=\"background-color:beige\"";} else {$stylephrase="";}
echo "".$spacer;
echo $equalitycounter.". 19".$fleertiffanyyears." Fleer Tiffany";
echo " (".$fleerses.") |
\r\n";
} //end if
} //end for next
$fleerupdatetiffanyyears=96;
$fleerupdatequery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$fleerupdatetiffanyyears." Fleer Update #%'";
$fleerupdatetiffanyquery = "SELECT fullname, COUNT(fullname) FROM cardtable WHERE fullname LIKE '19".$fleerupdatetiffanyyears." Fleer Update Tiffany #%'";
$fleerupdate=mysql_query($fleerupdatequery);
$fleerupdatetiffany=mysql_query($fleerupdatetiffanyquery);
while($row = mysql_fetch_array($fleerupdate)){
$fleerupdatees = $row[COUNT('fullname')];}
while($row2 = mysql_fetch_array($fleerupdatetiffany)){
$fleerupdatetiffanyses = $row2[COUNT('fullname')];
}
if ($fleerupdatees == $fleeupdatetiffanyses){
$equalitycounter++;
if ($equalitycounter<10) {$spacer=" ";}
if ($equalitycounter>9 && $equalitycounter<100) {$spacer=" ";}
if ($equalitycounter>99) {$spacer="";}
if ($equalitycounter%2==1) {$stylephrase="style=\"background-color:beige\"";} else {$stylephrase="";}
echo "".$spacer;
echo $equalitycounter.". 19".$fleerupdatetiffanyyears." Fleer Update Tiffany";
echo " (".$fleertiffanyupdatees.") |
\r\n";
} //end if
$cardarrayquery = "SELECT fullname, aname, printname FROM cardtable WHERE aname <> 'mlbwnonastros' AND fullname != ' ^' AND printname LIKE '--%' AND printname NOT LIKE '--#%' ORDER BY fullname ASC";
$cards=mysql_query($cardarrayquery);
while($row = mysql_fetch_array($cards)){
$ungroomedbase= $row['fullname'];
$ungroomedbase = str_replace("'","\\\\\''",$ungroomedbase);
$ungroomedbase= explode("#",$ungroomedbase);
$ungroomedbase1= explode("Unnumbered",$ungroomedbase[0]);
$groomedbase=trim($ungroomedbase1[0]);
$printname = $row['printname'];
$printname = str_replace("'","\\\\\''",$printname);
$printname= str_replace("--","",$printname);
if (strpos($printname,"(")>0 and strpos($printname,"/") > strpos($printname,"(")) {
$limited = substr($printname,strpos($printname,"/")+1,strpos($printname,")")-strpos($printname,"/")-1);} else {$limited="";}
if ($limited=="") {$limitedslash="";} else {$limitedslash="/";}
$printname= explode("#",$printname);
$printname1= explode("Unnumbered",$printname[0]);
$groomedprintname=trim($printname1[0]);
$groomedparallel=str_replace($groomedprintname,"",$groomedbase);
for ($i=0;$i0) {$adjustment=4;}
if (strpos($cardarray[2][$l],"04 Leaf Certified Materials Mirror White Materials Fabric") >0) {$adjustment=5;}
if (strpos($cardarray[2][$l],"04 Leaf Certified Materials Mirror Red Materials Bat") >0) {$adjustment=5;}
if (strpos($cardarray[2][$l],"04 Leaf Certified Materials Mirror Red Materials Combo") >0) {$adjustment=6;}
if (strpos($cardarray[2][$l],"04 Leaf Certified Materials Mirror Red Materials Fabric") >0) {$adjustment=6;}
if (strpos($cardarray[2][$l],"08 Upper Deck Heroes Jersey") >0) {$adjustment=1;}
if (strpos($cardarray[2][$l],"92 Topps Gold") >0) {$adjustment=-1;}
if (strpos($cardarray[2][$l],"6 Upper Deck Special F/X") >0) {$adjustment=1;}
$cardarray[2][$l]=str_replace("\\\\\\\''","'",$cardarray[2][$l]);
$straightparallel = trim(str_replace($cardarray[1][$l],"",$cardarray[2][$l]));
if (($basecounterarray[$l] + $adjustment == $parallelcounterarray[$l]) && $parallelcounterarray[$l] > 1 && trim($straightparallel) != "") {
$equalitycounter++;
if ($limited1[$l]> 0) {$metric = number_format(($basecounterarray[$l]/$limited1[$l]) * 100,2);} else {$metric="--";}
if ($equalitycounter<10) {$spacer=" ";}
if ($equalitycounter>9 && $equalitycounter<100) {$spacer=" ";}
if ($equalitycounter>99) {$spacer="";}
if ($equalitycounter%2==1) {$stylephrase="style=\"background-color:beige\"";} else {$stylephrase="";}
echo "".$spacer;
echo $equalitycounter.". ".$cardarray[2][$l]." ".$limited1slash[$l].$limited1[$l]."";
echo " (".$basecounterarray[$l].") | ".$metric." | \r\n";
}
$adjustment=0;
}
mysql_close ($connid);