function index(){
$shopid=0;
if($this->isGet()){
$shopid=$this->_param('shop_id');
trace(ACTION_NAME.':'.$shopid);
$this->assign('shop_id',$shopid);
}
$ft=M('food_type');
if($shopid==0){
$list=$ft->select();
}else{
$list=$ft->where('shop_id="'.$shopid.'"')->select();
}
$this->assign('list',$list);
$this->display();
}我在本地用的是tp的云平台版本本地代码运行正常
放到sae上总是偶尔有几个模版变量不解析
在本地可以的
FoodTypeAction.class.php<scfunction CreateNewFoodtype()
{
window.location.href = 'aimai/3/index.php/FoodType/create/shop_id/14';
}
</sc
同样的代码,在本地是这样 d
<sc
function CreateNewFoodtype()
{
window.location.href = 'aimai/3/index.php/FoodType/create/shop_id/{$shop_id}';
}
</sc
在服务器上是这样的
也就是在{$shop_id}在sae上不解析
是因为js的缘故吗?
最佳答案