alert(id);
$.ajax({
type:"POST",
dataType:"text",
data:{"typeId":id},
url:'__CONTROLLER__/index/',//目标地址
success:function(){
$("#" + id).css("background","red");
},
})
}
public function entert(){
$entert =D('entert');
$typeId = $_POST['typeId'];
echo $typeId;
if(I('typeId')!=''){
$date['typeId'] =I('typeId');
$enterts=$entert->where($date)->select();
$this->assign('enterts',$enterts);
}else{
$enterts=$entert->select();
$this->assign('enterts',$enterts);
}
}
最佳答案