I am trying to print out two dimensional arrays from the results of an sql statement in php
so far i have this code
for ($i=0; $i < count($searchResults); $i++) {
print "<tr>";
print "<td>";
print "$searchResults[$i]['username']";
print "</td>";
print "<td>";
print "<a href=\"viewprofile.php?email=$searchResults[$i]['email']
\">$searchResults[$i]['email']</a>";
print "</td>";
print "</tr>";
}
but instead of printing out the value in the array it prints out things like $array['username'] instead and i dont want to use for each loops since the second condition has to be a link any ideas?