|
123456789101112131415161718192021222324252627 |
- <?php
-
- class
- Chat
- {
- var $id;
- var $user_id;
- var $pass;
-
- function
- insert ():
- int
- {
- $sql = "
- INSERT INTO
- chats (
- user_id,
- text)
- VALUES
- (
- {$this -> user_id},
- '{$this -> text}')";
- $GLOBALS['__db_connection'] -> query ($sql)
- or die ("db_insert error $sql");
- }
- }
-
|