Browse files

Merge pull request #2154 from ibolmo/fix-2110-docs-request-json-onfai…

…lure

Fixes #2110.
  • Loading branch information...
2 parents f6d4e91 + 9c5d965 commit 27c958b142060af8d2e8b83be06ce3f7b8eab512 @cpojer cpojer committed Dec 5, 2011
Showing with 16 additions and 0 deletions.
  1. +16 −0 Docs/Request/Request.JSON.md
View
16 Docs/Request/Request.JSON.md
@@ -47,6 +47,18 @@ Fired when the parsed JSON is not valid and the secure option is set.
1. text - (string) The response text.
2. error - (string) The error message.
+#### failure
+
+Fired when the request failed (error status code), or when JSON string could not be parsed.
+
+##### Signature:
+
+ onFailure(xhr)
+
+##### Arguments:
+
+xhr - (XMLHttpRequest) The transport instance.
+
### Returns:
* (*object*) A new Request.JSON instance.
@@ -59,3 +71,7 @@ Fired when the parsed JSON is not valid and the secure option is set.
alert(person.height); // alerts "170 cm".
alert(person.weight); // alerts "120 kg".
}}).get({'firstName': 'John', 'lastName': 'Doe'});
+
+### See Also:
+
+[Request](/core/Request/Request)

0 comments on commit 27c958b

Please sign in to comment.