x14oL
V2EX  ›  PHP

Laravel CSRF 验证问题错误?

  •  
  •   x14oL · Nov 25, 2015 · 3779 views
    This topic created in 3862 days ago, the information mentioned may be changed or developed.
    表单里面添加了
    <input type="hidden" name="_token" value="{!! csrf_token() !!}">
    提交数据里面正确包含了_token 的值
    但是每次提交依然会提示
    TokenMismatchException in VerifyCsrfToken.php line 53:

    到群里发现有人遇到同样的问题,不知道又没人解决的。
    2 replies    2015-11-25 12:00:53 +08:00
    jjplay
        1
    jjplay  
       Nov 25, 2015
    <input type="hidden" name="_token" value="{{ csrf_token() }}">
    shy52110
        2
    shy52110  
       Nov 25, 2015
    楼上正解
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5623 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 55ms · UTC 08:06 · PVG 16:06 · LAX 01:06 · JFK 04:06
    ♥ Do have faith in what you're doing.