What is the maximum length of data transferred by GET and POST_PHP Tutorial

WBOY
Release: 2016-07-13 10:31:22
Original
1366 people have browsed it

In various web development languages, data is basically transferred between each page. The more commonly used data transfer methods in web development are get post. Until now, I have only known that the amount of data transferred by get is larger than The amount of data transferred by post is smaller, so you still need to use post to transfer large amounts of data. But how much data can the maximum amount of data transferred by get post be? Never figured it out.

Due to work needs today, I have to figure this issue out. Let’s talk about the maximum length of data transmitted by GET and POST.

get submits data through URL, so the amount of data that can be submitted by GET is directly related to the maximum length that the URL can achieve. Many articles say that the data submitted through GET can only be up to 1024 bytes. In fact, there is no upper parameter limit for URLs, and the HTTP protocol specification does not limit the URL length. This limit is imposed by specific browsers and servers. IE's limit on URL length is 2083 bytes (2K+35 bytes). For other browsers, such as FireFox, Netscape, etc., there is no length limit. At this time, the limit depends on the server's operating system. That is, if the URL is too long, the server may reject the request or make an incomplete data request due to security settings.

Theoretically, there is no size limit for post, and the HTTP protocol specification does not impose any size limit. However, in fact, the amount of data that post can transmit depends on the server settings and memory size. Because the data volume of our posts rarely exceeds MB, we rarely feel the limit of the data volume of posts. However, in practice, if you upload files, you may find such a problem, that is, uploading relatively large files. When the file is sent to the server, it may not be uploaded. In PHP language, when checking the reason, you may see that there are parameters related to PHP uploading files. PHP has a limit on uploading by default. Generally, this value is 2MB. Change this value. You need to change the value of post_max_size in php.conf. This clearly illustrates the problem.

Articles you may be interested in

  • How to optimize servers, staticize, database optimization, and load balancing for high-traffic websites to achieve high load
  • smarty template How to use php functions in smarty templates and how to use multiple functions for one variable in smarty templates
  • js limits the text box to only input numbers (including decimal points)
  • Mysql database cache cache function analysis, debugging and Performance Summary
  • JS realizes the simulation of Sina Weibo lobby and Tencent Weibo homepage Weibo message scrolling effect
  • Image enlargement display special effect slimbox The most lightweight and powerful Jquery image enlargement effect
  • Solution to the "Invalid parameter encountered" error that pops up when CuteFTP connects to the ftp server
  • jquery implements the simulation of Sina Weibo lobby and Tencent Weibo homepage scrolling effect

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/764100.htmlTechArticleIn various web development languages, data is basically transferred between each page, which is more commonly used in web development. The data transmission method is get post. I have only known about get transmission...
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!