Willakuy ukhu
⚡️36-dars: PDO da details yangilash --------------------------------------------------- 🔬PDO bilan ma'lumot yangilash 🪛PDO yordamida MySQL da ma'lumot yangilash❗️ <?php $dsn = "mysql:host=localhost;dbname=test"; $username = "root"; $password = ""; try { $dbh = new PDO($dsn, $username, $password); $stmt = $dbh->prepare("UPDATE users SET email = :email WHERE name = :name"); $stmt->bindParam(':email', $email); $stmt->bindParam(':name', $name); $email = "[email protected]"; $name = "Ali"; $stmt->execute(); echo "Ma'lumot yangilandi"; } catch (PDOException $e) { echo "Xato: " . $e->getMessage(); } ?> 🔺Yuqoridagi kodda PDO yordamida MySQL da ma'lumot yangilash ko'rsatilgan❗️ --------------------------------------------------- #fast_coder#php_dars #php36#rustam_hikmatullayev --------------------------------------------------- 📡Kanalimiz: @Fast_Coder