Created
May 4, 2014 22:49
-
-
Save davidkryzaniak/1f7b8cedcc86ab41a58e to your computer and use it in GitHub Desktop.
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
<?php | |
//Get the body of the request | |
$body = file_get_contents("php://input"); | |
if(!empty($body)){ | |
$alertData = json_decode($body,TRUE); | |
//Save to database... or other stuff | |
}else{ | |
throw new Exception("Invalid Request"); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment