I want to popup message box when press edit button on my php page. After confirmation should pass data to edit page. now data is parsing to edit page without showing message. Please help me to solve this.
<?php
include 'connection.php';
//var_dump($_POST['search']);
$query= "select * from computer where lab_no like '%".$_POST["search"]."%'";
//var_dump($query);
$output='';
$result= mysqli_query($conn, $query);
if(mysqli_num_rows($result)>0){
$output.='
<table class = "table table-bordered table-hover">
<tr>
<th style="text-align:center">Computer Number</th>
<th style="text-align:center">Computer Name</th>
<th style="text-align:center">Brand</th>
<th style="text-align:center">Edit</th>
<th style= "text-align:center">Delete</th>
</tr>';
while($row= mysqli_fetch_array($result)){
$output.='
<tr>
<td style= "text-align:center">'.$row["token_number"].'</td>
<td style="text-align:center">'.$row["com_name"].'</td>
<td style="text-align:center">'.$row["brand"].'</td>
<td style="text-align:center"><a href=../htdocs/add-com_edit.php?com_num=' . $row["token_number"] . ' \"onclick=\"return confirm("Are You Sure to Update this Record?");\"><span class="btn-success form-control" style="text-align:center">Edit</span></td>
<td style="text-align:center"><a href=\"../htdocs/po_edit.php?ponum=" . $row["token_number"] . "\" onclick=\"return confirm("Are You Sure to Delete this Record?");\"><span class="btn-danger form-control" style="text-align:center">Delete</span></td>
<tr/>';
}
echo $output;
$output.='</table>';
}else{
echo"No Data Found!";
}
?>