william232
10-08-2006, 11:10 PM
i have a catalog for a shopping cart catalog page which does not display the the information of each field in the database which i have is called "image" and this is what i have.
$cid=($_GET['cid']);
if($_GET['cid'])
{
$cQuery="SELECT * FROM products WHERE cid='$cid'";
$result=mysqli_query($con,$cQuery);
if(!$result)
{
echo "Error:".mysqli_error($con);
}
else
{
$count=$result->num_rows;
if($count>0)
{
while($data=$result->fetch_assoc())
{
$pid=$data['pid'];
$items[]=$data['productName'];
$images=$data['image'];
$imagesalttag=$data['imagesalttag'];
$prices[]=$data['ProductCost'];
$desc[]=$data['ProductDescription'];
}
}
else
{
echo "<br/>There is no products in the catalog,Please contact the webmaster of this store<br/>";
}
}
}
This is the line for it
echo "<tr><td><img src".$data['image']."></td>
Got,Any idea wats wrong?
$cid=($_GET['cid']);
if($_GET['cid'])
{
$cQuery="SELECT * FROM products WHERE cid='$cid'";
$result=mysqli_query($con,$cQuery);
if(!$result)
{
echo "Error:".mysqli_error($con);
}
else
{
$count=$result->num_rows;
if($count>0)
{
while($data=$result->fetch_assoc())
{
$pid=$data['pid'];
$items[]=$data['productName'];
$images=$data['image'];
$imagesalttag=$data['imagesalttag'];
$prices[]=$data['ProductCost'];
$desc[]=$data['ProductDescription'];
}
}
else
{
echo "<br/>There is no products in the catalog,Please contact the webmaster of this store<br/>";
}
}
}
This is the line for it
echo "<tr><td><img src".$data['image']."></td>
Got,Any idea wats wrong?