0
can anyone help me with this error i am not able to get this. Notice: Undefined index: id in C:\xampp\htdocs\project\Book_store\
Notice: Undefined index: id in C:\xampp\htdocs\project\Book_store\admin\process_del_book.php on line 4 <?php require('includes/config.php'); $query="delete from book where b_id =".$_GET['id']; mysqli_query($conn,$query) or die("can't Execute..."); header("location:all_book.php.php"); ?>
6 odpowiedzi
+ 9
Check if the $_GET['id'] is set
if(isset($_GET['id'])) {
$query="delete from book where b_id =".$_GET['id'];
}
Undefined index means that you are trying to access data in array that doesn't exist.
+ 2
You can post your own question about your problem.
Inamdar Inamdar
+ 1
When you call the $_GET super global variable it retrieves variables from the url of the page (like anything after the ? located after the page name.) You need to make sure that there is something that says id=someValue. If not it will not work
0
Sir please help me
0
css and JavaScript please help
0
sir CSS animation