From eb21bbdd550e4d1efc9a4c6e506eb64ba2cf9842 Mon Sep 17 00:00:00 2001 From: friendica Date: Mon, 27 Jan 2014 18:37:06 -0800 Subject: Ajaxchat package has way too many incompatible assumptions - after a lot of review, we can't work with it without re-writing huge chunks. Think I'll just start fresh. Ajax chat isn't that hard and we can do stuff with it that you just can't do with other chat clients because - well we've got zot. --- .../ajaxchat/chat/lib/class/AJAXChatMySQLQuery.php | 89 ---------------------- 1 file changed, 89 deletions(-) delete mode 100644 library/ajaxchat/chat/lib/class/AJAXChatMySQLQuery.php (limited to 'library/ajaxchat/chat/lib/class/AJAXChatMySQLQuery.php') diff --git a/library/ajaxchat/chat/lib/class/AJAXChatMySQLQuery.php b/library/ajaxchat/chat/lib/class/AJAXChatMySQLQuery.php deleted file mode 100644 index f2f3fd466..000000000 --- a/library/ajaxchat/chat/lib/class/AJAXChatMySQLQuery.php +++ /dev/null @@ -1,89 +0,0 @@ -_sql = trim($sql); - $this->_connectionID = $connectionID; - if($this->_connectionID) { - $this->_result = mysql_query($this->_sql, $this->_connectionID); - if(!$this->_result) { - $this->_errno = mysql_errno($this->_connectionID); - $this->_error = mysql_error($this->_connectionID); - } - } else { - $this->_result = mysql_query($this->_sql); - if(!$this->_result) { - $this->_errno = mysql_errno(); - $this->_error = mysql_error(); - } - } - } - - // Returns true if an error occured: - function error() { - // Returns true if the Result-ID is valid: - return !(bool)($this->_result); - } - - // Returns an Error-String: - function getError() { - if($this->error()) { - $str = 'Query: ' .$this->_sql ."\n"; - $str .= 'Error-Report: ' .$this->_error."\n"; - $str .= 'Error-Code: '.$this->_errno; - } else { - $str = "No errors."; - } - return $str; - } - - // Returns the content: - function fetch() { - if($this->error()) { - return null; - } else { - return mysql_fetch_assoc($this->_result); - } - } - - // Returns the number of rows (SELECT or SHOW): - function numRows() { - if($this->error()) { - return null; - } else { - return mysql_num_rows($this->_result); - } - } - - // Returns the number of affected rows (INSERT, UPDATE, REPLACE or DELETE): - function affectedRows() { - if($this->error()) { - return null; - } else { - return mysql_affected_rows($this->_connectionID); - } - } - - // Frees the memory: - function free() { - @mysql_free_result($this->_result); - } - -} -?> \ No newline at end of file -- cgit v1.2.3