Дополнен 2 года назад
ошибка
otice: Undefined index: full_name in
Notice: Undefined index: email in
Notice: Undefined index: link in
Warning: mysqli_fetch_assoc() expects parameter 1 to be mysqli_result, bool given in
Дополнен 2 года назад
ошибка в строке
$full_name = $_POST['full_name'];
$email = $_POST['email'];
$link = $_POST['link'];
if ($myrow = mysqli_fetch_array($result))
{
echo "<table border=1>\n";
echo "<tr><th>id</th><th>Full_Name</th><th>E-mail</th></tr>\n";
do
{
printf("<tr>
<td>%s</td>
<td><a href='%s'>%s</a></td><td>%s</td>
<td><a href='update.php?ID=" . $myrow["ID"] . "'>Изменить</a></td>
<td><a href='delete.php?ID=" . $myrow["ID"] . "'>Удалить</a></td>
</tr>\n", $myrow["ID"], $myrow["link"], $myrow["full_name_workers"], $myrow["E-mail"]);
}
while ($myrow = mysqli_fetch_array($result));
echo "</table>\n";
}
else
{
echo "запись не найденa";
}
$full_name = $_POST['full_name'];
$email = $_POST['email'];
$link = $_POST['link'];
$worker_id = $_GET['ID'];
$worker = mysqli_query($conn, " UPDATE `workers` SET `full_name_teacher` = '$full_name', `E-mail` = '$email', `link` = '$link' WHERE `workers`.`ID` = '$worker_id' ");
$teacher = mysqli_fetch_assoc($worker);
echo
"
<form method='post'>
<input type='hidden' name='id' value= '$worker_id'>
<p>имя</p>
<input type='text' name='full_name' value= '$full_name'>
<p>email</p>
<input type = 'email' name = 'email' value = '$email'>
<p>link</p>
<input type = 'url' name = 'link' value = '$link'>
<button ' type = 'submit' name = 'button' >Отправить</button>
<button type = 'reset' >Очистить</button>
</form>";