繁体   English   中英

Laravel 7.6 419 页面在表单提交时已过期

[英]Laravel 7.6 419 page expired on form submission

我正在尝试提交一个表单,它只是将我重定向到未指定的位置(到文件夹/index.blade.php),而不用 419 Page Expired 保存表单。 我尝试了其他方法来重定向到我想要的地方,但它不起作用。 我已经为正在运行的博客构建了一个 crud,并且我创建了另一个 controller 来保存联系表格。

<form role="form" method="POST" enctype="text/plain" action="{{action('LeadsController@store')}}">

        @csrf

        <div class="form-group">
            <label for="name">Name</label>
            <input type="text" name="name" value="" class="form-control" autocomplete="off" placeholder="Name">
        </div>

        <div class="form-group">
            <label for="email">Email</label>
            <input type="email" name="email" value="" class="form-control" autocomplete="off" placeholder="Email">
        </div>

        <div class="form-group">
            <label for="phone">Phone</label>
            <input type="text" name="phone" value="" class="form-control" autocomplete="off" placeholder="Phone">
        </div>

        <div class="form-group">
            <label for="requirement">Requirement</label>
            <input type="text" name="requirement" value="" class="form-control" autocomplete="off" placeholder="requirement">
        </div>


        <button type="submit" class="btn btn-outline-primary">Submit</button>

        </form>

确保您已将“网络”中间件用于表单端点路由。 此中间件负责 web 会话

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM