Quote:
Originally Posted by zerovic
Show me a print_r of your array and I can help you further.
|
This is literally all the code I have in the page (its real basic).
Quote:
<?php
$id=intval($_GET['id']);
if($id==0)
{
header( "Location: /search" ); //or any other page like 404
exit;
}
$pdo=hookitup();
$table = "ProductLibrary";
$sql="select * from " . $table . " where ID=" . $pdo->quote($id);
//echo "sql=" . $sql . "<br>";
$stmt=$pdo->query($sql);
//echo "rows back=" . $stmt->rowcount() . "<br>";
$row=$stmt->fetch(PDO::FETCH_ASSOC);
$id = $row['ID'];
$Category = $row['Category'];
$Name = $row['Name'];
$One = $row['One'];
$Two = $row['Two'];
$Three = $row['Three'];
$Four = $row['Four'];
?>
|
Im just echo'ing the data onto the page where I need to display it from the array.