Javascript Object Notation (JSON) Is What I Meant
I have been of late learning about AJAX and its integration with a ColdFusion application. As I started to understand the whole Xml Http Connection object and methodology I started to develop a form of dynamic Javascript code that would be passed back from the ColdFusion server and then evaluated by the web browser at the end of the AJAX call. It turns out, not suprisingly, that that already exists. It's called JSON or Javascript Object Notation. Furthermore, JSON looks very in depth in a conversion area where I only began to scratch the surface. Very cool stuff. So now, I get to look into JSON and see how it can be incorporated into my ColdFusion application framework. From what I have read so far, it seems they have conversion scripts for most scripting languages. Even if they don't I can always convert something from ASP or PHP to ColdFusion.
Reader Comments
hello,
I am trying to configure json in jrun. any help?
@John,
I am not sure what you mean.
Ben,I am trying to use JSON in the JRUN application server.
@John,
Right, but what does that mean? JSON is just a data formatting standard (like XML). What are you trying to do with it in JRUN?
Ben,
I am trying to send json object as a response through webservice deployed in JRUN server, to a request raised from aspx file. But it failed. If we try sending a String as response it works well.
Thanks
@John,
I am not too familiar with the .NET framework or ASPX. I can tell you that when I want to return JSON from a ColdFusion application, I just use this:
<cfcontent
type="application/json"
content="#toBinary( toBase64( myJSONString ) )#"
/>
My JSON values are always strings - I am not sure what difference you mean between JSON and "String" as I typically view these as one and the same in ColdFusion. I think you might need to talk to someone who knows more about .NET specifically.
@Ben,
Thanks for your reply.. We are currently returning the json object as string too.
Thank you so much for your help.
Appreciate it :)
@John,
No problem at all. Glad we could have a good conversation about it.