public function index(){
$Dao = M("zhaopin");
// 构造查询条件
$condition['Position'] = $_GET['Position'];
$condition['Recruitment'] = $_GET['Recruitment'];
$condition['Position'] = array('like',"%".$_GET['Position']."%");
$condition['Recruitment'] = array('like',"%".$_GET['Recruitment']."%");
// 计算总数
$count = $Dao->where($condition)->count();
// 导入分页类
import("ORG.Util.Page");
// 实例化分页类
$p = new Page($count,40);
// 获取查询参数
$map['Position'] = $_GET['Position'];
$map['Recruitment'] = $_GET['Recruitment'];
foreach($map as $key=>$val) {
$p->parameter .= "$key=".urlencode($val)."&";
}
// 分页显示输出
$page = $p->show();
// 当前页数据查询
$list = $Dao->where($condition)->order('id DESC')->limit($p->firstRow.','.$p->listRows)->select();
// 赋值赋值
$this->assign('page', $page);
$this->assign('list', $list);
$this->display();
}<!--区域筛选-->
<div class="cel_cat kuang kong">
<dl class="sz_area" style="margin-bottom:10px;">
<dt>招聘职位:</dt>
<dd>
<a href="/index.php/Zhaopin/" >全部</a>
<a href="/index.php/Zhaopin/index?Position=物流专员/助理">物流专员/助理</a>
<a href="/index.php/Zhaopin/index?Position=物流经理/主管">物流经理/主管</a>
<a href="/index.php/Zhaopin/index?Position=物流总监">物流总监</a>
<a href="/index.php/Zhaopin/index?Position=调度员">调度员</a>
<a href="/index.php/Zhaopin/index?Position=快递员">快递员</a>
<a href="/index.php/Zhaopin/index?Position=仓库管理员">仓库管理员</a>
<a href="/index.php/Zhaopin/index?Position=仓库经理/主管">仓库经理/主管 </a>
<a href="/index.php/Zhaopin/index?Position=装卸/搬运工">装卸/搬运工</a>
<a href="/index.php/Zhaopin/index?Position=供应链管理">供应链管理</a>
<a href="/index.php/Zhaopin/index?Position=单证员">单证员 </a>
<a href="/index.php/Zhaopin/index?Position=国际货运">国际货运</a>
<a href="/index.php/Zhaopin/index?Position=其它职位">其它职位</a></dd>
</dl>
<dl class="sz_area" id="sbl_">
<dt>区域:</dt>
<dd>
<a href="/index.php/Zhaopin/">全深圳</a>
<a href="/index.php/Zhaopin/index?Recruitment=罗湖区">罗湖区</a>
<a href="/index.php/Zhaopin/index?Recruitment=福田区">福田区</a>
<a href="/index.php/Zhaopin/index?Recruitment=南山区">南山区</a>
<a href="/index.php/Zhaopin/index?Recruitment=盐田区">盐田区</a>
<a href="/index.php/Zhaopin/index?Recruitment=宝安区">宝安区</a>
<a href="/index.php/Zhaopin/index?Recruitment=龙岗区">龙岗区</a>
<a href="/index.php/Zhaopin/index?Recruitment=光明新区">光明新区</a>
<a href="/index.php/Zhaopin/index?Recruitment=坪山新区">坪山新区</a>
<a href="/index.php/Zhaopin/index?Recruitment=大鹏新区">大鹏新区</a>
<a href="/index.php/Zhaopin/index?Recruitment=龙华新区">龙华新区</a>
<a href="/index.php/Zhaopin/index?Recruitment=深圳周边">深圳周边</a>
</dd> 我只要筛选2个就好了 但是我不会做了我想要下面图片的效果
最佳答案