How to solve the undefined index error? i have tried to make hidden field but not working also..
<?php
if($nume==0)
{ echo "You currently have no item to show"; }
else if(isset($_GET['msg']))
{
$msg = $_GET['msg'];
if($msg!='')
{
echo '<table border="1">
<tr>
<td><font color="red">'.$msg.'</font></td>
</tr>
</table>';
}
}
?></font></strong></p>
<table width="680px" cellspacing="0" cellpadding="5">
<tr bgcolor="#ddd">
<th width="220" align="left">Date </th>
<th width="200" align="left">Outlet </th>
<th width="130" align="left">Status</th>
<th width="70"> </th>
</tr>
<?php
$start=(isset($_GET['start'])) ? (int)$_GET['start']:0;
if(strlen($start) > 0 and !is_numeric($start))
{
echo "Data Error";
exit;
}
$eu = ($start - 0);
$limit = 5;
$this1 = $eu + $limit;
$back = $eu - $limit;
$next = $eu + $limit;
$result = mysql_query("SELECT DISTINCT orderdb.view,orderdb.odate,pstaff.outlet FROM orderdb,pstaff WHERE pstaff.outlet='SAP' AND orderdb.odate='2013-03-26' ORDER BY orderdb.odate limit $eu, $limit");
while($row = mysql_fetch_array($result))
{
echo"<input type='hidden' name='odate' value='". $row['odate'] ."' />";
echo"<input type='hidden' name='outlet' value='". $row['outlet'] ."' />";
echo "<td>" .$row['odate']. "</td>";
echo "<td>" .$row['outlet']. "</td>";
if($row['view']=='no'){
echo "<td>Not View Yet</td>";
echo "<td align='center'> <a href='astockoutlet.php?outlet=".$row['odate']."'>View</a> </td>";
}
echo "</tr>";
}
mysql_close($con);
?>
</table>
*Notice: Undefined index: odate in /home/lh026/public_html/pro1/astockoutlet.php on line 5
Notice: Undefined index: outlet in /home/lh026/public_html/pro1/astockoutlet.php on line 6*