Ik begrijp niet wat ik fout doe in de onderstaande code. Voegtoe word om de 1 of andere manier niet gevuld of gedefineerd??
<?php
error_reporting(E_ALL);
session_start();
//if $voegtoe = < 1
//{
//}
$dbLink = mysql_connect("localhost","140802","");
mysql_select_db('140802');
$strSqlCode = "SELECT * FROM producten;";
$oResultaat = mysql_query($strSqlCode);
print ("<table width=950 border=0>");
print ("<tr>");
print ("<td>");
print ("<b>");
print "product_id";
print ("</td>");
print ("</b>");
print ("<td>");
print ("<b>");
print "bestel";
print ("</td>");
print ("</b>");
While ($row = mysql_fetch_array($oResultaat))
{
print ("<tr>");
print ("<td>");
print $row['product_id'];
print ("</td>");
print ("<td>");
print ("<a href='?voegtoe=$row[product_id]'><img src='images/cart.jpg' border='0'>");
$_SESSION['voegtoe'] = $_GET['voegtoe'];
print ("</td>");
} //while loop word afgesloten
print ("</tr>");
print ("</table>");
//else
//{
//print "leeg";
//}
print $voegtoe;
print $voegtoe;
print $voegtoe;
?>
769 views