I get the error when trying to run this:
query(
Your query must have a problem which is causing $result to be an invalid resource.
Try checking for mysql_error() after the line on which you run your query.
Edit:
In fact, I would alter your DBConnector class function query() to something like the following, so that an identifiable error is thrown when you have a bad query:
function query($query) {
$this->theQuery = $query;
$queryId = mysql_query($query,$this->link);
if (! $queryId) {
throw new Exception(mysql_error().". Query was:\n\n".$query."\n\nError number: ".mysql_errno();
}
return $queryId;
}