From 82e3369632e0a1c47ba544e22414824013d8e112 Mon Sep 17 00:00:00 2001 From: usernamealreadyis Date: Fri, 15 Jan 2016 22:57:14 +0700 Subject: [PATCH 1/2] test There is a screencast that will help you get started if you prefer. Sphinx is a tool that makes it easy to create beautiful documentation. Assuming you have Python already, install Sphinx: commit 56ea800 --- test/test | 1 + 1 file changed, 1 insertion(+) create mode 100644 test/test diff --git a/test/test b/test/test new file mode 100644 index 000000000000..8b137891791f --- /dev/null +++ b/test/test @@ -0,0 +1 @@ + From a81ce393e5e9ba965a03b976cb9f0fdc74155416 Mon Sep 17 00:00:00 2001 From: usernamealreadyis Date: Thu, 21 Jan 2016 20:24:51 +0700 Subject: [PATCH 2/2] test.JSON Load the JSON data from test.js, passing along additional data, and access a name from the returned JSON data. If an error occurs, log an error message instead. ```javascript $.getJSON( "test.js", { name: "John", time: "2pm" } ) .done(function( json ) { console.log( "JSON Data: " + json.users[ 3 ].name ); }) .fail(function( jqxhr, textStatus, error ) { var err = textStatus + ", " + error; console.log( "Request Failed: " + err ); }); ``` --- test/test | 1 - test/test.JSON | 8 ++++++++ 2 files changed, 8 insertions(+), 1 deletion(-) delete mode 100644 test/test create mode 100644 test/test.JSON diff --git a/test/test b/test/test deleted file mode 100644 index 8b137891791f..000000000000 --- a/test/test +++ /dev/null @@ -1 +0,0 @@ - diff --git a/test/test.JSON b/test/test.JSON new file mode 100644 index 000000000000..145fa978bc44 --- /dev/null +++ b/test/test.JSON @@ -0,0 +1,8 @@ +$.getJSON( "test.js", { name: "John", time: "2pm" } ) + .done(function( json ) { + console.log( "JSON Data: " + json.users[ 3 ].name ); + }) + .fail(function( jqxhr, textStatus, error ) { + var err = textStatus + ", " + error; + console.log( "Request Failed: " + err ); +});