redirect重定向

post请求返回数据格式

  1. {
  2. "success": true,
  3. "message": "OK",
  4. "data": {
  5. "username": "mockedName",
  6. "phone": "12345678901",
  7. "email": "xxx.xxx@xxx.com"
  8. }
  9. }

image.png

默认的表单请求头

‘content-type’: ‘application/x-www-form-urlencoded’

  1. <form action="/api/get_user" method="POST">
  2. <input name="text" />
  3. <button>提交</button>
  4. </form>