I currently have the following array setup to display the states that have casting notices with the number of notices printed next to each location:
//display results
$NumRecords = 0;
while(($row = mysql_fetch_array($result)))
{
$NumRecords++;
$VState = $row["State"];
//spell out location
if ("al" == $VState) $VLocation = "Alabama";
else if ("ak" == $VState) $VLocation = "Alaska";
else if ("az" == $VState) $VLocation = "Arizona";
else if ("ar" == $VState) $VLocation = "Arkansas";
else if ("ca" == $VState) $VLocation = "California";
else if ("co" == $VState) $VLocation = "Colorado";
else if ("ct" == $VState) $VLocation = "Connecticut";
else if ("de" == $VState) $VLocation = "Delaware";
else if ("fl" == $VState) $VLocation = "Florida";
else if ("ga" == $VState) $VLocation = "Georgia";
else if ("hi" == $VState) $VLocation = "Hawaii";
else if ("id" == $VState) $VLocation = "Idaho";
else if ("il" == $VState) $VLocation = "Illinois";
else if ("in" == $VState) $VLocation = "Indiana";
else if ("ia" == $VState) $VLocation = "Iowa";
else if ("ks" == $VState) $VLocation = "Kansas";
else if ("ky" == $VState) $VLocation = "Kentucky";
else if ("la" == $VState) $VLocation = "Louisiana";
else if ("me" == $VState) $VLocation = "Maine";
else if ("md" == $VState) $VLocation = "Maryland";
else if ("ma" == $VState) $VLocation = "Massachusetts";
else if ("mi" == $VState) $VLocation = "Michigan";
else if ("mn" == $VState) $VLocation = "Minnesota";
else if ("ms" == $VState) $VLocation = "Mississippi";
else if ("mo" == $VState) $VLocation = "Missouri";
else if ("mt" == $VState) $VLocation = "Montana";
else if ("ne" == $VState) $VLocation = "Nebraska";
else if ("nv" == $VState) $VLocation = "Nevada";
else if ("nh" == $VState) $VLocation = "New Hampshire";
else if ("nj" == $VState) $VLocation = "New Jersey";
else if ("nm" == $VState) $VLocation = "New Mexico";
else if ("ny" == $VState) $VLocation = "New York";
else if ("nc" == $VState) $VLocation = "North Carolina";
else if ("nd" == $VState) $VLocation = "North Dakota";
else if ("oh" == $VState) $VLocation = "Ohio";
else if ("ok" == $VState) $VLocation = "Oklahoma";
else if ("or" == $VState) $VLocation = "Oregon";
else if ("pa" == $VState) $VLocation = "Pennsylvania";
else if ("ri" == $VState) $VLocation = "Rhode Island";
else if ("sc" == $VState) $VLocation = "South Carolina";
else if ("sd" == $VState) $VLocation = "South Dakota";
else if ("tn" == $VState) $VLocation = "Tennessee";
else if ("tx" == $VState) $VLocation = "Texas";
else if ("ut" == $VState) $VLocation = "Utah";
else if ("vt" == $VState) $VLocation = "Vermont";
else if ("va" == $VState) $VLocation = "Virginia";
else if ("wa" == $VState) $VLocation = "Washington";
else if ("wv" == $VState) $VLocation = "West Virginia";
else if ("wi" == $VState) $VLocation = "Wisconsin";
else if ("wy" == $VState) $VLocation = "Wyoming";
else if ("dc" == $VState) $VLocation = "District of Columbia";
else if ("australia" == $VState) $VLocation = "Australia";
else if ("england" == $VState) $VLocation = "England";
else if ("canada" == $VState) $VLocation = "Canada";
else if ("other" == $VState) $VLocation = "Other Countries";
else $VLocation = "";
print "<a href=\"castingresults.php?state=" . $row["State"] . "\">" . $VLocation . "</a> (" . $row["Count"] . ")<br>" ;
flush;
} //end of while loop
Which prints like this:
Nevada(4)
New York(32)
Texas(19)
This prints all location on top of each other(seperated by a <br>).
I want to have all the locations printed with 1/4 of them in each column of a table with 4 columns. But I only want the locations that have notices to print with a hyperlink and the number(count) of notices.
I need the locations distributed over four columns so that the user does not need to scroll.
ANY help and suggestion or solutions would be greatly appreciated.