rendered paste body public function query($sql = null) {
$this->sql = $sql == null ? $this->sql : $sql;
$this->result = mysql_query($this->sql, $this->connection) or die(mysql_error());
$this->get_num_rows();
}
public function select($where) {
$this->where = $where;
$this->what = $this->what == null ? '*' : $this->what;
$sql = $this->oncondition == null ? "SELECT $this->what FROM $this->where" : "SELECT $this->what FROM $this->where WHERE $this->oncondition";
$this->query($sql);
}
public function set_on($oncondition) {
$this->oncondition = $oncondition;
}