Skip to content

Instantly share code, notes, and snippets.

@colonelmac
colonelmac / gist:3662893
Created September 7, 2012 03:46
Testing REST API with jQuery
$(document).ready(function () {
// use JSON to structure your parameter
// { derp: 1, herp: 'hello' } equivalent to ?derp=1&herp=hello
var params = { };
function onsuccess(data, status, jqxhr) {
// data will be a native javascript object
console.log(data);
}