By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,466 Members | 1,141 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,466 IT Pros & Developers. It's quick & easy.

URL size

P: n/a
Hi,

I have a page where multiple fields can be edited:

Name Age DOB
[name1] [age1] [dob1]
[name2] [age2] [dob2]
[name3] [age3] [dob3]
[name4] [age4] [dob4]
[name5] [age5] [dob5]

Where you can type in any of the fields etc and with one click all
these get updated by Javascript concatenating them into one variable,
escaped and passed through GET.

However I've discovered that when there are LOTS of entries, I have a
problem - I.E. seems to restrict the length of a URL to 2KB whereas FF
appears to be much higher.

Is there an alternative way to somehow send this data to my PHP
script? Would POST face the same restrictions and is it better/worse
than using GET for AJAX?

Thanks

A

Nov 14 '07 #1
Share this Question
Share on Google+
3 Replies


P: n/a
UKuser wrote:
However I've discovered that when there are LOTS of entries, I have a
problem - I.E. seems to restrict the length of a URL to 2KB whereas FF
appears to be much higher.
Google for `IE OR "Internet Explorer" URL length'.
Is there an alternative way to somehow send this data to my PHP
script?
Yes.
Would POST face the same restrictions
No.
and is it better/worse than using GET for AJAX?
No.
PointedEars
--
Prototype.js was written by people who don't know javascript for people
who don't know javascript. People who don't know javascript are not
the best source of advice on designing systems that use javascript.
-- Richard Cornford, cljs, <f8*******************@news.demon.co.uk>
Nov 14 '07 #2

P: n/a
UKuser wrote:
I have a page where multiple fields can be edited:

Name Age DOB
[name1] [age1] [dob1]
[name2] [age2] [dob2]
[name3] [age3] [dob3]
[name4] [age4] [dob4]
[name5] [age5] [dob5]

Where you can type in any of the fields etc and with one click all
these get updated by Javascript concatenating them into one variable,
escaped and passed through GET.

However I've discovered that when there are LOTS of entries, I have a
problem - I.E. seems to restrict the length of a URL to 2KB
Correct:
http://support.microsoft.com/kb/208427
whereas FF appears to be much higher.
Yes it is, but the official recommendation says:

| Servers should be cautious about depending on URI lengths above
| 255 bytes, because some older client or proxy implementations
| may not properly support these lengths.

http://www.ietf.org/rfc/rfc2068.txt
Is there an alternative way to somehow send this data to my PHP
script?
Yes, by using POST.
Would POST face the same restrictions and is it better/worse
than using GET for AJAX?
I don't believe POST has a limit on request size; but web server and/
or application may set their own rules. You can send both GET and POST
requests in AJAX.

Hope this helps,

--
Bart

Nov 14 '07 #3

P: n/a
On 14 Nov, 16:27, Bart Van der Donck <b...@nijlen.comwrote:
UKuser wrote:
I have a page where multiple fields can be edited:
Name Age DOB
[name1] [age1] [dob1]
[name2] [age2] [dob2]
[name3] [age3] [dob3]
[name4] [age4] [dob4]
[name5] [age5] [dob5]
Where you can type in any of the fields etc and with one click all
these get updated by Javascript concatenating them into one variable,
escaped and passed through GET.
However I've discovered that when there are LOTS of entries, I have a
problem - I.E. seems to restrict the length of a URL to 2KB

Correct:http://support.microsoft.com/kb/208427
whereas FF appears to be much higher.

Yes it is, but the official recommendation says:

| Servers should be cautious about depending on URI lengths above
| 255 bytes, because some older client or proxy implementations
| may not properly support these lengths.

http://www.ietf.org/rfc/rfc2068.txt
Is there an alternative way to somehow send this data to my PHP
script?

Yes, by using POST.
Would POST face the same restrictions and is it better/worse
than using GET for AJAX?

I don't believe POST has a limit on request size; but web server and/
or application may set their own rules. You can send both GET and POST
requests in AJAX.

Hope this helps,

--
Bart
Thanks to both replies. I did a quick bit of investigating and looks
like POST is the way to go!! Thanks A

Nov 14 '07 #4

This discussion thread is closed

Replies have been disabled for this discussion.