+ * Load a remote page using an HTTP GET request, only if it hasn't
+ * been modified since it was last retrieved. All of the arguments to
+ * the method (except URL) are optional.
+ *
+ * @example $.getIfModified("test.html")
+ *
+ * @example $.getIfModified("test.html", { name: "John", time: "2pm" } )
+ *
+ * @example $.getIfModified("test.cgi", function(data){
+ * alert("Data Loaded: " + data);
+ * })
+ *
+ * @example $.getifModified("test.cgi",
+ * { name: "John", time: "2pm" },
+ * function(data){
+ * alert("Data Loaded: " + data);
+ * }
+ * )
+ *
+ * @test stop();
+ * $.getIfModified("data/name.php", function(msg) {
+ * ok( msg == 'ERROR', 'Check ifModified' );
+ * start();
+ * });
+ *
+ * @name $.getIfModified
+ * @type jQuery
+ * @param String url The URL of the page to load.
+ * @param Hash params A set of key/value pairs that will be sent to the server.
+ * @param Function callback A function to be executed whenever the data is loaded.
+ * @cat AJAX
+ */
+ getIfModified: function( url, data, callback, type ) {
+ jQuery.get(url, data, callback, type, 1);
+ },
+
+ /**
+ * Loads, and executes, a remote JavaScript file using an HTTP GET request.
+ * All of the arguments to the method (except URL) are optional.
+ *
+ * @example $.getScript("test.js")
+ *
+ * @example $.getScript("test.js", function(){
+ * alert("Script loaded and executed.");
+ * })
+ *
+ * @test stop();
+ * $.getScript("data/test.js", function() {
+ * ok( foobar == "bar", 'Check if script was evaluated' );
+ * start();
+ * });
+ *
+ * @name $.getScript
+ * @type jQuery
+ * @param String url The URL of the page to load.
+ * @param Function callback A function to be executed whenever the data is loaded.
+ * @cat AJAX
+ */
+ getScript: function( url, callback ) {
+ jQuery.get(url, callback, "script");
+ },
+
+ /**
+ * Load a remote JSON object using an HTTP GET request.
+ * All of the arguments to the method (except URL) are optional.
+ *
+ * @example $.getJSON("test.js", function(json){
+ * alert("JSON Data: " + json.users[3].name);
+ * })
+ *
+ * @example $.getJSON("test.js",
+ * { name: "John", time: "2pm" },
+ * function(json){
+ * alert("JSON Data: " + json.users[3].name);
+ * }
+ * )
+ *
+ * @test stop();
+ * $.getJSON("data/json.php", {json: "array"}, function(json) {
+ * ok( json[0].name == 'John', 'Check JSON: first, name' );
+ * ok( json[0].age == 21, 'Check JSON: first, age' );
+ * ok( json[1].name == 'Peter', 'Check JSON: second, name' );
+ * ok( json[1].age == 25, 'Check JSON: second, age' );
+ * start();
+ * });
+ * @test stop();
+ * $.getJSON("data/json.php", function(json) {
+ * ok( json.data.lang == 'en', 'Check JSON: lang' );
+ * ok( json.data.length == 25, 'Check JSON: length' );
+ * start();
+ * });
+ *
+ * @name $.getJSON
+ * @type jQuery
+ * @param String url The URL of the page to load.
+ * @param Hash params A set of key/value pairs that will be sent to the server.
+ * @param Function callback A function to be executed whenever the data is loaded.
+ * @cat AJAX
+ */
+ getJSON: function( url, data, callback ) {
+ if(callback)
+ jQuery.get(url, data, callback, "json");
+ else {
+ jQuery.get(url, data, "json");
+ }
+ },
+
+ /**
+ * Load a remote page using an HTTP POST request. All of the arguments to
+ * the method (except URL) are optional.
+ *
+ * @example $.post("test.cgi")
+ *
+ * @example $.post("test.cgi", { name: "John", time: "2pm" } )
+ *
+ * @example $.post("test.cgi", function(data){
+ * alert("Data Loaded: " + data);
+ * })
+ *
+ * @example $.post("test.cgi",
+ * { name: "John", time: "2pm" },
+ * function(data){
+ * alert("Data Loaded: " + data);
+ * }
+ * )
+ *
+ * @test stop();
+ * $.post("data/name.php", {xml: "5-2"}, function(xml){
+ * $('math', xml).each(function() {
+ * ok( $('calculation', this).text() == '5-2', 'Check for XML' );
+ * ok( $('result', this).text() == '3', 'Check for XML' );
+ * });
+ * start();
+ * });
+ *
+ * @name $.post
+ * @type jQuery
+ * @param String url The URL of the page to load.
+ * @param Hash params A set of key/value pairs that will be sent to the server.
+ * @param Function callback A function to be executed whenever the data is loaded.
+ * @cat AJAX