<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                合規國際互聯網加速 OSASE為企業客戶提供高速穩定SD-WAN國際加速解決方案。 廣告
                ## 獲取post提交的數據,必須先生成csrf秘鑰 ~~~ this.ctx.request.body ~~~ egg.js中要post數據必須先簽名認證 ## 1.訪問首頁先生成csrf秘鑰 ~~~ const Controller = require('egg').Controller; class HomeController extends Controller { async index() { /* 用戶訪問這個頁面的時候生成的秘鑰 */ console.log(this.ctx.csrf) await this.ctx.render('index',{ csrf:this.ctx.csrf }) } /* 接受post提交的數據 */ async add(){ this.ctx.body = "add" console.log(this.ctx.request.body) } } module.exports = HomeController; ~~~ ## 2.在index.html中使用這個秘鑰,才能在后臺獲取post數據 ~~~ <form action="/add?_csrf=<%= csrf%>" method='post'> <p>用戶名: <input type="text" name="username"></p> <p>密碼: <input type="password" name="password"></p> <input type="submit" value="提交"> </form> ~~~
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看