1$sql = "UPDATE users SET name=?, surname=?, sex=? WHERE id=?";$stmt= $pdo->prepare($sql);$stmt->execute([$name, $surname, $sex, $id]);
1$sql = "UPDATE users SET name=?, surname=?, sex=? WHERE id=?";$pdo->prepare($sql)->execute([$name, $surname, $sex, $id]);
1$data = [ 'name' => $name, 'surname' => $surname, 'sex' => $sex, 'id' => $id,];$sql = "UPDATE users SET name=:name, surname=:surname, sex=:sex WHERE id=:id";$stmt= $pdo->prepare($sql);$stmt->execute($data);