PHP
- 51 ответ
- 0 вопросов
28
Вклад в тег
$filename = $_FILES["filename"]["name"];
move_uploaded_file($_FILES["filename"]["tmp_name"], "avatar/$filename");
$query = $connection->prepare("UPDATE table_user SET avatar = :avatar WHERE user_id = :user_id");
$query->bindParam(':avatar', $filename);
$query->bindParam(':user_id', $user_id);
$query->execute();
use symfony/routing/YamlFileLoader as YFL;