Permalink
Browse files

custom http status code

  • Loading branch information...
1 parent 2fd63cc commit 1c93aba2d9966077f5aa7957832aafb7d397fd4b Mashape committed Feb 2, 2011
Showing with 6 additions and 0 deletions.
  1. +6 −0 mashape/mashape.php
View
@@ -43,6 +43,12 @@ protected static function addError($code, $message) {
$e = new MashapeAPIError($code, $message);
array_push(self::$errors, $e);
}
+
+ public static function setHttpStatusCode($statusCode) {
+ if (!empty($statusCode)) {
+ header("HTTP/1.0 " . $statusCode);
+ }
+ }
public static function parseBoolean($value) {
if ($value == "1" || strtolower($value) === "true") {

0 comments on commit 1c93aba

Please sign in to comment.