{"id":308,"date":"2014-11-05T18:53:10","date_gmt":"2014-11-05T22:53:10","guid":{"rendered":"http:\/\/www.joebillman.com\/blog\/?p=308"},"modified":"2014-11-05T18:53:10","modified_gmt":"2014-11-05T22:53:10","slug":"restful-calls-via-angularjs","status":"publish","type":"post","link":"https:\/\/www.joebillman.com\/blog\/?p=308","title":{"rendered":"RESTful calls via AngularJS"},"content":{"rendered":"<p>I&#8217;ve been doing more with AngularJS lately, it&#8217;s becoming really popular. Here&#8217;s how to do RESTful calls with Angular:<br \/>\n<\/p>\n<pre style=\"background-color:#e5e5e5;\">\nvar config = {headers:{'accept': 'application\/json',\n    'content-type': 'application\/json;charset=UTF-8'}};\n    \n$http.post(url, data, config).\n    success(function(response)\n    {\n        successHandler(response);\n    }).\n    error(function(response)\n    {\n        errorHandler(response);\n    });\n<\/pre>\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve been doing more with AngularJS lately, it&#8217;s becoming really popular. Here&#8217;s how to do RESTful calls with Angular: var config = {headers:{&#8216;accept&#8217;: &#8216;application\/json&#8217;, &#8216;content-type&#8217;: &#8216;application\/json;charset=UTF-8&#8217;}}; $http.post(url, data, config). success(function(response) { successHandler(response); }). error(function(response) { errorHandler(response); });<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,20],"tags":[],"class_list":["post-308","post","type-post","status-publish","format-standard","hentry","category-angularjs","category-javascript"],"_links":{"self":[{"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/308","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=308"}],"version-history":[{"count":0,"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/308\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=308"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=308"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.joebillman.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=308"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}