<?
class user extends db_object {

var $table_name = "users";

    function getList($start) {
        $res = array();
                                                                                                
        $semail = trim($_REQUEST["semail"]);
        $cond = (strlen($semail) > 2) ? "email LIKE '%".addslashes($semail)."%'" : "email != ''";

        $res["count"] = $this->find("count", $cond);
        if($res["count"] > 0) {
            $res["data"] = $this->findAll("*", $cond, $start, "id DESC");
        }
        return $res;
    }

}
?>