I use a content type of "application/json" and I normally use the header methods provided by CGI or CGI::Application rather than hand coding. If you want the onFailure to trigger, you'll need to set the appropriate http status (4xx, 5xx).
update: and by 'normally', I mean by following rfc 4627.
In reply to Re: [OT] Syntax for: AJAX Prototype JSON response
by derby
in thread [OT] Syntax for: AJAX Prototype JSON response
by graq
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |