Как мне...исправить неопределенную ошибку индекса
$name= stripslashes (trim($_POST['name'])); $surname= stripslashes (trim($_POST['surname'])); $email= stripslashes (trim($_POST['email'])); $password= stripslashes (trim($_POST['password'])); $age= stripslashes (trim($_POST['age'])); $cellphone= stripslashes (trim($_POST['cellphone'])); $address= stripslashes (trim($_POST['address'])); $query=mysql_($conn, "INSERT INTO 'students' ('null' ,'$name', '$surname', '$email', '$password', '$age', '$cellphone', '$address',)"); $result = mysqli_query($conn, $query);
Что я уже пробовал:
$name= stripslashes (trim($_POST['name'])); $surname= stripslashes (trim($_POST['surname'])); $email= stripslashes (trim($_POST['email'])); $password= stripslashes (trim($_POST['password'])); $age= stripslashes (trim($_POST['age'])); $cellphone= stripslashes (trim($_POST['cellphone'])); $address= stripslashes (trim($_POST['address'])); $query=mysql_($conn, "INSERT INTO 'students' ('null' ,'$name', '$surname', '$email', '$password', '$age', '$cellphone', '$address',)"); $result = mysqli_query($conn, $query);
Richard MacCutchan
Ваше назначение $query недопустимо.