By:fjhgx

以下是引用片段:

if($cateid)
{
        $container.=' and grouptype="'.$cateid.'"';
}
if($cityid)
{
        $container.=' and cityid="'.$cityid.'"';
}

$order=" order by recommend desc,sortorder desc";
$sql="select * from ".tname('groups')." where 1".$container." and ispassed=1 and lasttime>=".time().$order;

利用方式:

    http://localhost/api/apidata.php?container=1{sql}