"; function writeentries($tableguy,$caption) { global $connid; ECHO "Astroland E: The World's Most Complete Listing of Houston Astro Baseball Cards"; ECHO "

Astroland

"; ECHO "

\"The
"; $majorgif="major leaguer.GIF"; $defaultcardnumberfont="yellow"; $defaultplayerfont="white"; $defaultpositionfont="limegreen"; $defaultremarksfont="yellowgreen"; $defaultimagebordercolor="red"; $cardnumbersize="3"; $playersize="3"; $positionsize="3"; $remarkssize="4"; set_include_path('./public_html/astroland.net/'); include 'altarray.php'; echo" "; echo" "; echo"
"; echo"
"; echo"
"; echo" "; echo" "; echo" "; echo" "; echo" "; echo""; $i=1; $result = mysqli_query($connid, "SELECT * FROM Numbertable WHERE aname = '$tableguy' ") or die(mysqli_error()); while ($row = mysqli_fetch_assoc($result)) { $numbercards = $row['numbercards']; if ($numbercards < 60) { $openwindowwidth=400; $openwindowheight=400;} elseif (numbercards < 150) { $openwindowwidth=600; $openwindowheight=600; } else {$openwindowwidth=1000; $openwindowheight=800; } $aname = $row['aname']; $firstname = $row['firstname']; $lastname = $row['lastname']; $html = $row['html']; $position = $row['position']; $remarks = $row['remarks']; $image = $row['image']; $major = $row['major']; $syringe = $row['syringe']; $whiff = $row['whiff']; $top = $row['top_prospect']; $allstar = $row['allstar']; for ($k = 0;$k < count($tableimages); $k++) { if ($tableimages[$k][1] == $image) { $alttext = $tableimages[$k][2] ;}} $i++; if ($allstar<>"") {$cardnumberfont="gold"; $playerfont="gold"; $positionfont="gold"; $remarksfont="gold"; } else { $cardnumberfont=$defaultcardnumberfont; $playerfont=$defaultplayerfont; $positionfont=$defaultpositionfont; $remarksfont=$defaultremarksfont; } echo "\r\n"; echo "\r\n\r\n"; echo"
".$caption."
CARDS I HAVE "; echo" PLAYER POSITION "; echo" REMARKS
"; echo $numbercards; echo""; if ($numbercards < 16) { $j=0; echo " ";} $printname= $row['printname']; if (strlen($printname) > 45) { $offset = 0; // initial offset is 0 $spaceCounter = 0; // Check the rest of the string for spaces while($offset = strpos($printname," ",$offset + 1)){ if ($offset > 25 && $offset < 40) {$breakpoint = $offset;} } $printname=substr_replace($printname,"
          ",$breakpoint,0);} if (strpos($printname,"--") == "false") { $printname=substr_replace($printname,"       ",0,0); } echo $printname; echo "
"; } echo "

');return false\"onMouseover=\"window.status='The cards in my collection'; return true\" onMouseout=\"window.status='B All End All'; return true\">"; if ($top<>"") {echo "";} echo $firstname." ".$lastname; if ($top<>"") {echo "";} if ($numbercards > 1) {echo " Cards\r\n";} else {echo " Card\r\n";} } else { if ($numbercards > 99){ echo "
 
"; if ($top<>"") {echo "";} echo $firstname." ".$lastname; if ($top<>"") {echo "";} echo " Cards
"; } else { echo ""; if ($top<>"") {echo "";} echo $firstname." ".$lastname; if ($top<>"") {echo "";} echo " Cards"; } } if ($major<>"") { if ($syringe=="") { echo "
"; echo $position; echo "
 
";} else { echo "
"; echo ""syringe") {echo $syringe;} echo"
"; echo $position; echo "
 
"; } } else { if ($syringe<>"") { echo "
"; echo $position; echo "
\r\n";} else { echo ""; echo $position; echo "\r\n"; } } IF ($image ==""){ $image="comingsoon.GIF"; $alttext="Coming Soon"; } $fh = fopen($image, 'r') or die("can't open file"); list($width, $height) = getimagesize($image); if($width > 125 && $height >100) { $width=$width/2; $height=$height/2; } If ($i%4==1) { $defaultimagebordercolor = "forestgreen"; echo "
"; echo $remarks; echo "
"; echo "\"".$alttext."\""; } elseif ($i%4==2 && $width < 126 && strlen($remarks) < 400) { $defaultimagebordercolor = "yellow"; echo "
"; echo $remarks; echo " "; echo "\"".$alttext."\""; } elseif ($i%4==3 ) { $defaultimagebordercolor = "red"; echo "
" ; echo "\"".$alttext."\""; echo "
"; echo $remarks; } elseif ($i%4==0 && $width < 126 && strlen($remarks) < 400) { $defaultimagebordercolor = "purple"; echo "\r\n\r\n"; } echo "
"; echo "\"".$alttext."\""; echo ""; echo $remarks;} else { $defaultimagebordercolor = "red"; echo ""; if ($whiff <>"") { echo "
"; echo $remarks; echo "
"; echo "\"".$alttext."\""; } fclose($fh); echo"
";} echo "

"; } mysqli_close ($connid); ?>