Array to string conversion
looked around and everything seems to be more complex that what I am
trying to do.
I have queried an item from a previous page and brought it forward.
$varVeh=$_POST['Veh_num'];
I echo that and it show the proper number....
I then want to use the name associated with that number in a table title.
so I do another query:
$sql_vehName="select Veh_name from hc_vehicle_type where Veh_num=$varVeh";
$result_vehName = mysql_query($sql_vehName);
$vehName=mysql_fetch_assoc($result_vehName);
echo $vehName;
echo "<table border='1'>";
echo "<tr><td>Best Scores for</td><td>$vehName</td> </tr>";
Without using the fetch I get resource #6.
No comments:
Post a Comment