Created
October 29, 2014 01:59
-
-
Save webinfinita/9d1d682c923deb5fdf61 to your computer and use it in GitHub Desktop.
Filters for API's
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App::before(function($request) | |
{ | |
header('Access-Control-Allow-Origin: *'); | |
header('Access-Control-Allow-Methods: GET, POST, OPTIONS'); | |
header('Access-Control-Allow-Headers: Origin, Content-Type, Accept, Authorization, X-Request-With'); | |
header('Access-Control-Allow-Credentials: true'); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment