alert('Please enter a tracking Number')"; } else { $sql = "SELECT * FROM track WHERE pid = '$tid'"; $result = mysqli_query($link, $sql); if (mysqli_num_rows($result) > 0) { $row = mysqli_fetch_assoc($result); $pid = $row['pid']; if (isset($row['pid'])) { $pid = $row['pid']; if ($tid == $pid) { header("Location:result.php?track=$tid"); } else { echo ""; } } } } } ?> Track Your Parcel