Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I want to get some data from a server and store it in a two-dimentional javascript array. I want to use "get" method for it, with a form, but I don't understand the procedure behind it.
Can anyone suggest anything? I'd appreciate any input.

I'm not sure I can envision the scenario here...You want to get some data from a server and store it in javascript, but you want to do it via GET instead of POST?
It sounds like you may be talking about AJAX (Asynchronous Java And XML)...Where you create an xmlhttprequest object with javascript and asynchronously get data from the server - all with no 'postback.' Google Suggest and Google maps are two good examples of the capabilities of AJAX.
More typically, the server just outputs the javascript and the data it will need into the HTML page itself, so javascript doesn't need to make any server requests.
I enjoy AJAX stuff and would be happy to help (particularly if you're using .NET), but you haven't given us enough information to determine which solution is right for your project. If you can give us a little more info on what you're actually trying to accomplish we can give you better answers.
Good luck,
-SN

Yes, Ajax is a big word in my project. At this point I used an object made by Active Widgets, asynchronous data loading, that loads xml data, but now I need to load/request plane text from the server that will come in a format of a 2d javascript array, like this:
[[data,data,data],[data,data,data]]
I test my pages in Firefox and IE, so whatever I do, has to work in both browsers.
So, is there a way to load that string of brackets and text and somehow assign it to a javascript array?

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |