Having some trouble with some code i wrote 2 years ago,
Getting spammed with Notice: Use of undefined constant.
<?php
include ("conectarbd.php");
$sql = "SELECT * from stock WHERE tipo='microonda'";
$result = mysql_query($sql,$con);
echo "<table border=\"0\">";
echo "<tr><td></td><td>".ID."</td><td>".Nombre."</td><td>".Modelo."</td></tr>";
while($registro=mysql_fetch_array($result))
{
echo '<tr><td>'.$registro[0].'</td><td>'.$registro[2].'</td><td>'.$registro[3].'</td><td><a href=profile.php?id='.$registro[0].'><img src="images/arrowbw.png" border="0"title="Profile"></a></td></tr>';
}
echo "</table>";
mysql_close($con);
?>
Thanks
IDNombreandModeloare treated as constants.If they are meant to be strings (they are meant to be the column headings, right?), you want to put them inside quotes.