Дополнен 3 года назад
<?php
if (isset($_POST['nazv'])) {
$q_test = $_POST['q_test'];
'$f_test = $_POST['f_test'];
$g_test = $_POST['g_tesr'];
$stmt = "INSERT INTO `disciplines` (`test`, `test`, `test`)
VALUES ('$q_test', '$f_test', $g_test);";
$conn=mysqli_connect('localhost','root',"","new") or die ("no");
if ($conn->query($stmt) === TRUE) {
echo "New ";
} else {
echo "Mistake: " . $sql . "
" . $conn->error;
}
mysqli_close($conn);
} else {
echo "No ";
}
?>
Дополнен 3 года назад
echo "Mistake: " . $sql . "
" . $conn->error; ошибка тут