Chrome: Source of Post Data?

前端 未结 2 559
一整个雨季
一整个雨季 2020-11-29 01:07

I am using Chrome 15 with Developer Tools to investigate HTTP POST requests. After sending a request, in the Network tab under Headers there is a section c

相关标签:
2条回答
  • 2020-11-29 02:00

    Chrome 29–56, and possibly beyond

    Finally (maybe already with version 28), it's simple. Just click on view source next to Form Data:

    DevTools screen shot

    Also, at least in version 56, post data may be found in the Headers tab, under Request Payload.

    Older versions

    • Chrome 27

      1. Right click in the Name/Path panel in the Network tab.

      2. Select: Copy all as HAR

      3. In the Console, write har=, then paste the HAR, and hit return.

      4. Count from the top the position of the request you are interested, starting at 0. Store the position in: pos

      5. To get the post data source, execute: har.log.entries[pos].request.postData.text

    • even older:

      1. Right click on the Name/Path of the entry in the Network tab.

      2. Select: Copy entry as HAR

      3. In the Console, write har=, then paste the HAR, and hit return.

      4. To get the post data source, execute: har.request.postData.text

    If there is a simpler way, I am happy to hear about it!

    0 讨论(0)
  • 2020-11-29 02:10

    it's easier if you:

    1. go to Network
    2. click the entry you want to see the post for
    3. click on the headers tab
    4. scroll down to Form Data
    0 讨论(0)
提交回复
热议问题