Can anyone here see anything wrong with this, it shows Pics that are in my database, (connection not shown), it shows different pics on a different page for different people, the $person is the persons name that is shown in the url like show.php?find=Erik, the only problem is is that it only shows Eriks, and will not show anyone elses. Anyone got any ideas
| Code: |
|
$row = mysql_fetch_array($result); extract($row); if (@$_GET["find"] == $person) { $per_row = 4; echo "$person"; $result2 = mysql_query("SELECT pic,person FROM pics WHERE person='$person'"); for ($i=1; $i<mysql_num_rows($result2); $i++) { $pic2 = mysql_result($result2,($i-1)); echo "<td align='center'><img src='$pic2'></td>"; if ($i%$per_row == 0) echo "</tr><tr>"; } } else { echo "<font face='Verdana, Arial, Helvetica, sans-serif' size='2'>Sorry no pics found</font>"; } |
