Home » Php » PHP: MySQLi webpage returns to 1st page when I perform an edit on a page [on hold]

PHP: MySQLi webpage returns to 1st page when I perform an edit on a page [on hold]

Posted by: admin October 18, 2018 Leave a comment

Questions:

php mysqli ..i want a code which returns to or is redirected to page 2 if edit or update is done on page 2 or returns to page 3 if edit or update is done on a record on page 3 and the same for other page

$result = "UPDATE acc SET System='$system',brand='$brand', model='$model', SerialNumber='$serial', Supplier='$supplier', DatePurchased='$date', DateDisposed='$Disposed', dept='$dept'  WHERE ID=$id";
    $query = mysqli_query($link, $result);




    //redirecting to the display page. In our case, it is index.php
    header('refresh: 1; url= ./newdisplay.php?page=2');
Answers: