Today, I am reading the $ _ GET function in W3C, which is limited to less than 100 characters, and some people can also see that it is less than 2 kb, in addition, we can see that the $ _ GET method has no length limit, because the amount of data that can be submitted is related to the URL length, and the URL has no length limit. Can you tell me whether this method exists... today at W3C
$_GET
Function, which is limited
Up to 100 characters
And some people also see that
Less than 2 kb
In addition, we can see that the $ _ GET Method
No length limit
Because the amount of data that can be submitted is related to the URL length, and the URL has no length limit.
Is there a limit on the length of this method? What is there?
Reply content:
Today at W3C$_GET
Function, which is limitedUp to 100 characters
And some people also see thatLess than 2 kb
In addition, we can see that the $ _ GET MethodNo length limit
Because the amount of data that can be submitted is related to the URL length, and the URL has no length limit.
Is there a limit on the length of this method? What is there?
The HTTP protocol never specifies the length limit of GET/POST requests. The length limit mainly depends on the decision and settings of the browser and the web server. The settings of various browsers and web servers are different.
Generally, the default webserver limit is 8 KB, but you can modify the configuration.
The maximum values of MSIE and Safari on the browser side are 2 kb, 4 kb for Opera, and 8 KB for Firefox. From the perspective of cross-browser applications, you should select the minimum 2KB.
In my impression, a long time ago, the url length was generally limited to 1024 bytes. Different browsers had little difference and I don't know the current situation.
Inhttp
In the protocolurl
The maximum length of a url is usually related to the user's browser. The acceptable maximum length of a browser is often different.
IE browser:2083
Characters
Firefox:65,536
Characters
Safari:80,000
Characters
Opera:190,000
Characters
Google:8182
Characters
In addition, different web servers can accept different url lengths.
I recently encountered this problem raised by the landlord. The scenario is to use the GET method to submit a form while saving some information. Then, an error is reported, indicating that the server request limit is exceeded, the reason is that too much information is saved, and the GET method will display all the data on the URL. After the method is changed to POST, the problem does not exist. Baidu once said that the URL length is restricted by the browser, and different browsers have different length restrictions.
Sqrtqiezi is right.
Whether it is post or get, there must be a length limit, which is determined by the minimum value set between the server and the browser.
Get is generally the largest in 2 K