聯(lián)系官方銷售客服
1835022288
028-61286886
判斷后前臺(tái)沒有顯示 _msg的提示, 代碼寫在控制器的
前臺(tái)只是執(zhí)行了效果
代碼:
public function index() { //接收數(shù)據(jù) $post_id = \Phpcmf\Service::L('input')->post('post_id'); //內(nèi)容id $post_title = \Phpcmf\Service::L('input')->post('post_title'); //內(nèi)容標(biāo)題 $post_mbrid = \Phpcmf\Service::L('input')->post('post_mbrid'); //會(huì)員id $post_inputtime = SYS_TIME; //當(dāng)前時(shí)間 //變量為空 if(empty($post_id) && empty($post_title) && empty($post_mbrid)){ return $this->_msg(0,'非法操作'); } $rt = \Phpcmf\Service::M()->db->table('member_dowlog')->insert([ 'cid' => $post_id, 'title' => $post_title, 'uid' => $post_mbrid, 'inputtime' => $post_inputtime, ]); if($rt['code']){ return $this->_msg(1,'操作成功!'); }else{ return $this->_msg(0,'操作失?。?#39;); } }
這個(gè)寫法很標(biāo)準(zhǔn),沒有任何問題的
回復(fù)@官方研發(fā)技術(shù)-羅老師
不知道為啥 下面的判斷沒跳轉(zhuǎn) msg 頁面