Exemple #1
0
 public function addUser($token, $uid)
 {
     $user = array("token" => $token, "fb_uid" => $uid);
     $sql = SqlUtils::insert(self::TABLE_USERS, $user);
     @$this->handle->exec($sql);
     // maybe already exists
     return $this->handle->lastInsertRowID();
 }
Exemple #2
0
 public function addNewBook($book = array())
 {
     if (count($book) == 0) {
         return 0;
     }
     $sql = SqlUtils::insert(self::TABLE_BOOKS, $book);
     @$this->handle->exec($sql);
     // maybe already exists
     return $this->handle->lastInsertRowID();
 }