Open saweetha opened 6 years ago
Try replacing this:
if(isset($_POST['id'])!='') {
With this:
if(isset($_POST['id'])&&$_POST['id']!='') {
It's still adding new pages, not updating. Any source that i need to show more to make your work easy?
I found that your id input value doesn't have an =
after value....
It shows like this
<input type="hidden" name="id" value"<?php echo $opened['id']; ?>"
And it should be like this
<input type="hidden" name="id" value="<?php echo $opened['id']; ?>"
Also, if that doesn't work, check that opened is defined before everything please.
I can't update the pages, whenever I try to update it, it's turning into new pages. I can't find out where things get wrong.
this is the index coding <?php
Start the session:
session_start();
if(!isset($_SESSION['username'])) { header('Location: login.php'); }
?>
<?php include('config/setup.php'); ?>
<!DOCTYPE html>
Admin Dashboard
Page could not be added because: '.mysqli_error($dcb); $message .= '
'.$q.'
'; } } ?>