WANTED!! YOUR Opinion: best to use in AJAX Response.
Posted: Fri Aug 25, 2006 8:56 pm
Hi Guys,
First, some background information for people new to AJAX, or just not familiar with the subject/concept. (This would be not needed for 98% of people on this forum since most of us have used some sort of Javascript in combination with other scripting languages etc.... but dosen't hurt to provide background information on the topic.)
Recently, I stumbled upon this page on the web (through google search)
http://www.quirksmode.org/blog/archives ... espon.html
can't tell you how much this has helped me!!
Now comes the participation part Yay!!
I would like to ask, what do YOU use for Ajax response? XML HTML or JSON?
If you used any of the three in the past, and now switched to different method, why?
on a side note:
Some people (I consider myself in this group) do not know what they are talking about when they say "AJAX this" "AJAX that" blah blah blah.
Some of the time, when we say AJAX, we actually are looking for AJAH functionality.
Ok, so back to the topic, sorry for the digression. So, what kind of format do you respond with when utilizing AJAX or AJAH.
As for me, I have rarely dealt with JSON... actually only once:
ole was helping me in one of the features that I wanted to add to my project....
On a regular basis, I now deal with HTML only. So, in a way this thread will help me shape my ideas. (I am leaning towards using JSON strings in the future though)
Why?
-Matt
First, some background information for people new to AJAX, or just not familiar with the subject/concept. (This would be not needed for 98% of people on this forum since most of us have used some sort of Javascript in combination with other scripting languages etc.... but dosen't hurt to provide background information on the topic.)
Recently, I stumbled upon this page on the web (through google search)
http://www.quirksmode.org/blog/archives ... espon.html
can't tell you how much this has helped me!!
Now comes the participation part Yay!!
I would like to ask, what do YOU use for Ajax response? XML HTML or JSON?
If you used any of the three in the past, and now switched to different method, why?
on a side note:
Some people (I consider myself in this group) do not know what they are talking about when they say "AJAX this" "AJAX that" blah blah blah.
Some of the time, when we say AJAX, we actually are looking for AJAH functionality.
Ok, so back to the topic, sorry for the digression. So, what kind of format do you respond with when utilizing AJAX or AJAH.
As for me, I have rarely dealt with JSON... actually only once:
ole was helping me in one of the features that I wanted to add to my project....
On a regular basis, I now deal with HTML only. So, in a way this thread will help me shape my ideas. (I am leaning towards using JSON strings in the future though)
Why?
quoted from the aforementioned siteJavaScript does not allow you to access documents (be they XML or HTML) that come from another server. However, if you import a JSON file as a script tag you circumvent this problem, and any JSON data can be imported into any website.
-Matt