Hi Everyone, I have the following prepared statement and I am having problems displaying data from my test db
Can someone help me out please.
$STM = $dbh->prepare('SELECT * FROM tbl WHERE var = :lsecure');
$STM->bindParam(':lsecure', $var);
$STM->execute();
$count = $STM->rowCount();
$row = $STM -> fetch();
if($count > 0){
foreach($results as $row);
$varname = $row['var'];
}
The $var is being displayed from session data and I know it is correct.
Thanks in advance.