SELECT m.name, m.year FROM movie
SELECT m.name, m.year, d.description FROM movie m
JOIN descriptions d ON d.id=m.descriptions_id
SELECT m.name, m.year, d.description, c.name category_name FROM movie m
JOIN descriptions d ON d.id=m.descriptions_id
JOIN categories c ON c.id=m.category_id
$(".hours").bind("keyup change", function (e) {
const tval = $(this);
if ((!$.isNumeric(tval.val()) && tval.val().toLowerCase() !== 'нет') || parseInt(tval.val()) >= 24) {
tval.addClass("inputError");
return;
}
if (tval.val() === "") {
tval.prop('required', true);
return;
}
tval.removeClass("inputError");
tval.prop('required', false);
});
<?php
$users = getData();
?>
<form action="update.php" method="POST">
<label for="user">Username:</label>
<input type="text" name="user">
<label for="password">Password:</label>
<input type="password" name="password">
<select name="id">
<option>Выберите пользователя</option>
<?foreach($users as $user):?>
<option value="<?=$user['id']?>"><?=$user['username']?></option>
<?endforeach?>
</select>
<input type="submit" value="UPDATE">
</form>