Results 1 to 5 of 5
Sep 20, 2008, 07:31 #1
when iframe's URL is too long (more than 2083 bytes), using self submitting form?
In some situation where we does an <iframe src="..."> </iframe>, the URL can be longer than 2083 bytes long and it seems it will choke IE 6 and 7. Even though Apache 2.x supports URL up to 8k long, IE will not work when the URL is longer than 2083 bytes.
All the params should be short, except one that is like "user_review", which can be any length, depending on how long the user wrote.
Also a catch might be that, if we also specify a src=" ... " for the iframe initially, then the iframe might start loading first, and then all of a sudden, the form will auto submit to this iframe, and then it will cause net traffic twice? (the first one being canceled but still induce some system and net overhead). Thanks.
Last edited by winterheat; Sep 20, 2008 at 11:37.
Sep 20, 2008, 11:22 #2
- Join Date
- Apr 2007
- 0 Post(s)
- 0 Thread(s)
Use POST instead of GET for the form method. PHP's default maximum POST data length is 8MB.
Don't put a query string in the form's action URI. Put the query string parameters in hidden form fields instead.
Sep 20, 2008, 11:36 #3
yes, i forgot to mention it is POST. and it is added to the original post.
actually... using those params in the URL will work too... the target can use $_GET or $_POST to get them... it probably is best to make them all hidden input, but as params on the URL they work on all current browsers I tried. Thank you though.
Sep 20, 2008, 14:06 #4
- Join Date
- Sep 2005
- Sydney, NSW, Australia
- 24 Post(s)
- 1 Thread(s)
If you use POST then the limit on how much data you can pass is so high that it would take someone several days of typing in the form to overflow it.
If you use POST then the form fields do not end up in the URL so if it is in the URL then you are using GET rather than POST.
Sep 20, 2008, 22:18 #5
the fact is you can post to a target with params on the URL and both POST and GET params will be passed to the php file.