Ben .. ben bana yaşam için atanan değerleri almak için görünmüyor olabilir pdo + mysql kullanarak temel hazırlanan açıklama yapmaya çalışıyorum :/
$dbh = new PDO('mysql:dbname=users;host=127.0.0.1', 'localAPI', 'localAPI');
$a = 'asdf';
$sth = $dbh->prepare("INSERT INTO users (userName, userPass, accountStatus) VALUES (':a', ':userPass', 'unconfirmed')");
$sth->bindParam(':a', $a, PDO::PARAM_STR);
$sth->execute();
Any ideas? Thanks in advance!!
Tablo sonuçları:
mysql> select * from users;
+--------+----------+-----------+---------------+-------------+---------+---------------------+----------+------------+---------+------+
| userId | userName | userPass | accountStatus | accountType | balance | tCreated | tUpdated | tLastLogin | promoId | ref |
+--------+----------+-----------+---------------+-------------+---------+---------------------+----------+------------+---------+------+
| 1 | :a | :userPass | unconfirmed | user | 0 | 2010-12-12 13:42:10 | NULL | NULL | NULL | NULL |
+--------+----------+-----------+---------------+-------------+---------+---------------------+----------+------------+---------+------+