国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

Laravel5.2 will add web middleware to routing by default. How to disable it?
某草草
某草草 2017-05-16 16:52:38
0
4
1051

Laravel5.2 will add Web middleware to routing by default. How to disable it?

web contains sessioncsrftoken. However, session and csrf are not used at all in the asynchronous notifications of Alipay and WeChat. How to disable.

I don’t want to touch the middleware configuration of verifycsrftoken.

某草草
某草草

reply all(4)
左手右手慢動作

Solved.

appHttpProvidersRouteServiceProvider.phpmapRoute 取消強制給加上的web中間件調(diào)用。自己在自己的路由中需要的時候增加 middleware=>web That’s it

僅有的幸福

Try not to modify itapp/Http/Kernel.php,極不推薦關(guān)閉CSRF。
修改app/Http/Middleware/VerifyCsrfToken.php to exclude the specified URL from CSRF verification.

<?php

    namespace App\Http\Middleware;

    use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as BaseVerifier;

    class VerifyCsrfToken extends BaseVerifier
    {
        /**
         * 指定從 CSRF 驗證中排除的URL
         *
         * @var array
         */
        protected $except = [
            'testCsrf'
        ];
    }
迷茫

/app/Http/Kernel.php31AppHttpMiddlewareVerifyCsrfToken::class,Delete or comment

淡淡煙草味

It would be better if you take your routing out of the web middleware group.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template