Shiro Ajax請求權限不滿足,攔截後解決方案

這裏有一個前提,我們知道Ajax不能做頁面redirect和forward跳轉,所以Ajax請求假如沒登錄,那麼這個請求給用戶的感覺就是沒有任何反應,而用戶又不知道用戶已經退出了.解決辦法: 後臺代碼  String requestedWith = request.getHeader("x-requested-with"); if (requestedWith != null && requ
相關文章
相關標籤/搜索