Image Not Pulling in PHP script

Hi There,

I have a php script that pulls an image and I keep getting a broken image returning.

[php]//collect
if (isset($_POST[‘searchVal’])) {
$searchq = $_POST[‘searchVal’];

	$query = mysql_query("SELECT * FROM Players WHERE FirstName LIKE '%$searchq%' OR LastName Like '%$searchq%' OR FullName Like '%$searchq%' ") or die(mysql_error());
	$count = mysql_num_rows ($query);
	if($count == 0){
		$output = 'There was no search results!';
	}else{
		while($row = mysql_fetch_array($query)) {
		      $fname = $row['FirstName'];
			  $lname = $row['LastName'];
			  $PlayerID = $row['PlayerID'];

$iPlayerID = $_GET[“PlayerID”];
$iNationID = $_GET[“NationID”];

$oPlayerInfo = mysql_query("
SELECT Players.PlayerID, Players.FirstName, Players.LastName, Players.NationID
FROM Players
ORDER BY Players.LastName;
") or die(mysql_error());

			  $output .= "<img src=\"http://www.cnghl.org/cnghldb/nation/".$iNationID.".gif\"><a href=\"cnghlplayerinfo.php?PlayerID=".$row['PlayerID'].'" style="text-decoration:none;">'.$row['FirstName']." ".$row['LastName']." ".$row['Sec']." ".$row['byear']."<br>";
			  
	}
}

}
echo ($output);
?>[/php]

When I copy image location I get the link “http://www.cnghl.org/cnghldb/nation/.gif” so it seems like it’s not picking up the $iNationID.#.gif up. What am I doing wrong here?

Thanks for your help.

I figured it out!

Sponsor our Newsletter | Privacy Policy | Terms of Service