An online tool is used to simulate the transmission of post request data packets, but the results are not expected and I do not know what is wrong.

Source: Internet
Author: User
You can set a password for a blog post. You need to enter a password for reading. I have created a test page with the password 123456. Now, I want to read the Blog content through the program. The http request header information obtained through firebug packet capture analysis is as follows: {code ...} the Post parameter is as follows: tb_password123...

You can set a password for a blog post. You need to enter a password for reading.
I created a test page, password123456
Now, if you want to read the Blog content through a program, the http request header information obtained through firebug packet capture analysis is as follows:

POST/hongfei/p/3705089.html HTTP/1.1 Host: www. cnblogs. comUser-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv: 29.0) Gecko/20100101 Firefox/29.0 Accept: text/html, application/xhtml + xml, application/xml; q = 0.9, */*; q = 0.8Accept-Language: zh-cn, zh; q = 0.8, en-us; q = 0.5, en; q = 0.3Accept-Encoding: gzip, deflateReferer: http://www.cnblogs.com/post/readauth? Url =/hongfei/p/3705089.html Cookie: cookie information Connection: keep-alive

The Post parameter is as follows:
tb_password=123456
Then, use an online tool to send a post request. The result is as follows.
The result is not the Blog content.
I don't know where the error is. I hope you can give me some advice.

Reply content:

You can set a password for a blog post. You need to enter a password for reading.
I created a test page, password123456
Now, if you want to read the Blog content through a program, the http request header information obtained through firebug packet capture analysis is as follows:

POST/hongfei/p/3705089.html HTTP/1.1 Host: www. cnblogs. comUser-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv: 29.0) Gecko/20100101 Firefox/29.0 Accept: text/html, application/xhtml + xml, application/xml; q = 0.9, */*; q = 0.8Accept-Language: zh-cn, zh; q = 0.8, en-us; q = 0.5, en; q = 0.3Accept-Encoding: gzip, deflateReferer: http://www.cnblogs.com/post/readauth? Url =/hongfei/p/3705089.html Cookie: cookie information Connection: keep-alive

The Post parameter is as follows:
tb_password=123456
Then, use an online tool to send a post request. The result is as follows.
The result is not the Blog content.
I don't know where the error is. I hope you can give me some advice.

Content-TypeWrong,Content-Type:application/x-www-form-urlencoded.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.