I wonder why it doesn't want to retrieve the P_id information when I press hapus/delete button. It suppose to bypass P_id value so that I know which to delete.
The url remains empty: http://localhost/innovation/script_shop/hapus.php?P_id=
<?php
$result = mysql_query("SELECT * FROM stock")
or die(mysql_error());
echo "<table border=1>";
echo "<tr>";
echo "<th>Produk</th><th>Jumlah</th><th>Tanggal</th>";
echo "</tr>";
$i=0;
while($row = mysql_fetch_array( $result )) {
$result2=($i%2)?'#DFA09D':'white';
echo "<tr bgcolor='$result2'>";
echo "<td>";
echo $row['Produk'];
echo "</td>";
echo "<td>";
echo $row['Jumlah'].'<br/>';
echo "</td>";
echo "<td>";
echo $row['Tanggal'];
echo "</td>";
echo "<td>";
echo "Edit";
echo "</td>";
echo "<td>";
echo "<a href='hapus.php?P_id='".$row['P_id'].">hapus</a>";
echo "</td>";
echo "</tr>";
$i++;
}