Permalink
Browse files

Merge pull request #20 from primetimesolutions/master

Added section for extra HTTP headers
  • Loading branch information...
2 parents ae1788d + af10d54 commit 252fd8cdf0d9717327463f9c0dcd328024e04dda @jbroadway committed Jan 5, 2013
Showing with 16 additions and 0 deletions.
  1. +16 −0 README.textile
View
16 README.textile
@@ -59,3 +59,19 @@ class Song extends ActiveResource {
var $extra_params = '?key=123456789';
}
</pre>
+
+h2. Extra Http Headers
+
+If you need to add extra http request headers you can set $request_headers
+
+<pre>
+<?php
+
+require_once ('ActiveResource.php');
+
+class Song extends ActiveResource {
+ var $site = 'http://localhost:3000/';
+ var $element_name = 'songs';
+ var $request_headers = array("x-api-key: some-api-key-here");
+}
+</pre>

0 comments on commit 252fd8c

Please sign in to comment.