Skip to content

Instantly share code, notes, and snippets.

@allanortiz
Last active December 30, 2015 18:34
Show Gist options
  • Select an option

  • Save allanortiz/7774f4d4e51f9bae60a7 to your computer and use it in GitHub Desktop.

Select an option

Save allanortiz/7774f4d4e51f9bae60a7 to your computer and use it in GitHub Desktop.
Header cross origin.
<?php
header("Access-Control-Allow-Credentials: true");
header("Access-Control-Allow-Origin: *");
header("Access-Control-Allow-Methods: GET, POST, PUT, DELETE, OPTIONS");
header("Access-Control-Allow-Headers: Origin, X-Requested-With, Content-Type, Accept, Authorization");
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment