RynMan Posted April 4, 2010 Share Posted April 4, 2010 Hi guys I'm struggling a little with the concept arrays, not sure why this doesn't work. I have this code: $result9 = mysql_query("SELECT * FROM `tblclientinformation` LEFT JOIN tblphotos ON tblclientinformation.KAMClientID = tblphotos.KAMClientID WHERE Current = 1 AND Gender='$Gender' AND Actor=TRUE $LocationQ ORDER BY LastName LIMIT $RecordNumber, $RecordsOnPage", $connection); if (!$result9) { die("Database query failed" . mysql_error()) ; } Then later on down the page I want to use it like this.... while ($row9 = mysql_fetch_array($result9)) { echo '<td width="125" align="center"><a class="actorsListLink" href="cvprofile.php?ID='.$row9["KAMClientID"].'"><img src="headshot/ListHeadShot/'.$ListHeadShot.'" border="0" width="72" height="90" /><br />'.$row9["FirstName"]."<br />".$row9["LastName"].'<br />'.$row9["KAMClientID"].'</a></td>'; } Everything echos here except "KAMClientID". The first and last names work fine, but the ID does not. I've done a print_r for my array and it is in there as the first item in the array [0]. When I substitute the "KAMClientID" for zero, it works perfectly. Why do my other accept the text, however this one does not? Link to comment https://forums.phpfreaks.com/topic/197533-question-about-my-array/ Share on other sites More sharing options...
TeddyKiller Posted April 4, 2010 Share Posted April 4, 2010 Why do my other accept the text Aren't ID's best as int(11) either auto-increment if its the id of the row, or not auto-increment for else? I can't really see the problem, have you tried taking away the capital letters? Link to comment https://forums.phpfreaks.com/topic/197533-question-about-my-array/#findComment-1036714 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.