0
我已經爲codeigniter應用程序啓用CSRF保護。有很多網址添加和排除,但是他們的2,而其他URL做工精細Codeigniter CSRF錯誤雖然排除了URL,但您所請求的操作不被允許
if (stripos($_SERVER["REQUEST_URI"],'api/controller1/index') == FALSE &&
stripos($_SERVER["REQUEST_URI"],'api/controller2/index') == FALSE
//URLs here
) {
$config['csrf_protection'] = TRUE;
}else{
$config['csrf_protection'] = FALSE;
}
$config['csrf_exclude_uris'] = array(
'api/controller1/index',
'api/controller2/index',
//URLs here
);
那麼如何解決這個問題變得越來越「您所請求的操作是不允許的」的錯誤?