json

How can I get a list of the differences between two JavaScript object graphs?

I want to be able to get a list of all differences between two JavaScript object graphs, with the property names and values where the deltas occur. For what it is worth, these objects are usually retrieved from the server as JSON and typically are no more than a handful of layers deep (i.e. it may be an array of objects that themselves...

correct HTTP header for json file

I've searched around and found two different ways to define Content-type for JSON file loaded with php. header('Content-type: text/json'); header('Content-type: application/json'); which one should be used ? ...

How to pass complex type using json to ASP.NET MVC controller

I have a View that allows a user to enter/edit data for a new Widget. I'd like to form up that data into a json object and send it to my controller via AJAX so I can do the validation on the server without a postback. I've got it all working, except I can't figure out how to pass the data so my controller method can accept a complex Wi...

How to consume data from an ASP.NET MVC from a different website?

I am playing around with ASP.NET MVC for the first time, so I apologize in advance if this sounds academic. I have created a simple content management system using ASP.NET MVC. The url to retrieve a list of content, in this case, announcements, looks like: http://www.mydomain.com/announcements/list/10 This will return the top ten ...

What's the best practice to render JSON data in JSPs?

I need to render JSON data in my JSPs for some AJAX requests. I'd like to know what's the best way to do it in terms of easy to use and stability. ...

JSON in Flex. "Access of undefined property JSON"

I am trying to parse JSON in an Adobe Flex app, using http://www.mikechambers.com/blog/2006/03/28/tutorial-using-json-with-flex-2-and-actionscript-3/'>This Tutorial Unfortunately, Flex Builder 3 is flagging a "Access of undefined property JSON" error on the line var arr:Array = (JSON.decode(rawData) as Array); I don't know what it wan...

UpdatePanel seems to struggle with huge data as AsynPostBack. jSonSerializer maxLength doesn't help

Hi All, I have a ASP.NET 3.5 App and trying to update a Update Panel which has a nested custom control. In that custom control is a ComponentArt Gird, which gets filled by almost 13MB of Data (Yes, I could chunck that...) at this Update. I have a hidden button wihtin the update Panel, which I trigger by JS from client side, when I need...

ASP.NET - What is the correct approach to JSON based web services with jQuery?

What is the correct way to convert ASP.NET SOAP-based web services to JSON-based responses? ...And then call these from jQuery? What are "best practices" when integrating jQuery based AJAX and ASP.NET? Articles? Books? ...

Best JSON library to use when developing an iPhone application?

There are a few JSON libraries/frameworks available for objective-c developers, but I wanted to get the opinion of the resident gurus here on which one is the best, and why. Any thoughts? ...

What is JSON?

What is JSON? ...

Deserializing a complex JSON result (array of dictionaries) with TouchJSON

I did a few tests with TouchJSON last night and it worked pretty well in general for simple cases. I'm using the following code to read some JSON content from a file, and deserialize it: NSString *jsonString = [[NSString alloc] initWithContentsOfFile:@"data.json"]; NSData *jsonData = [jsonString dataUsingEncoding:NSUTF32BigEndianStringE...

How to correctly serialize a base class to JSON in silverlight?

I have the following structure: class Base { } class Child : Base { } When I try to do the following: DataContractJsonSerializer serializer = new DataContractJsonSerializer(typeof(Base)); serializer.WriteObject(stream, data); It fails with the error message: Type 'MyNamespace.Child' with data contract name 'Child:http://...

What is the best, light-weight JSON/ajax script?

I am creating a joomla plugin and want to load an array of images after the page has loaded. To do that, I'm currently using mootools.js to call myserver URL, obtain the JSON response and parse the response into javascript variables that represent each image url. It works great, but mootools.js is appropriately named since it is a real...

How to Consume JSON Web Services from a Windows Client

Is it possible to consume a JSON enabled WCF Web Service from a standard Proxy Client ie not Javascript? Basically I want to minimize the payload size between 2 web services. ...

Where can I get the JSONRequestError code?

Following the JSONRequest proposal, I've found code for the JSONRequest object. However, this object depends on JSONRequestError, and the code for that is nowhere to be found. Anyone know where I can find the code? Thanks in advance! ...

A working Json library for Javascript?

I went to http://www.json.org/js.html and downloaded the json2.js, thinking i'd be fine, afterall that site is on the top in a google search for 'json javascript' - also they have this really cool url :) So i've been working a bit with it and it seemed fine, but now i start running into trouble with it - it simply won't parse certain st...

Cross Domain JSON Enabled WCF

Hello, I have a WCF Service decorated with WebInvoke attributes and WebHttp binding for JSON enabling. The service can be accessed from JavaScript until we try to make it working cross domain. Can you please recommend how to get this to work cross domain? We've tried to create proxy web handler but it gives "Bad Request" everytime Web...

Generics / JSON JavaScriptSerializer C#

Hi I'm building a winForms app in NET3.5SP1 using VS2008Express. Am trying to deserialize an object using the System.Web.Script.Serialization library. The error is: Type 'jsonWinForm.Category' is not supported for deserialization of an array. Cheers! using System; using System.Collections.Generic; using System.ComponentModel; using ...

How do I imitate the ASP.NET AjaxOptions delegate functions?

When using the Ajax.BeginForm() helper in ASP.Net MVC, I can pass options with names of different functions, for example one to run OnBegin, one for OnSuccess etc. How do these work "under the hood"? The reason I'm asking is that I'm extending this to provide a jQuery based alternative, and I need to figure out how to get from having th...

JSON - Slashes and application type..refactoring

Hi My code works (yeah!) which sends json to a server.. would appreciate any thoughts on refactoring 1) My C# code sends this json to the server {\"firstName\":\"Bill\",\"lastName\":\"Gates\",\"email\":\"[email protected]\",\"deviceUUID\":\"abcdefghijklmnopqrstuvwxyz\"} Which I have to get rid of the slashes on the server side....not ...