From edd7351b76685bb769f157a192b167b29e0ad6c0 Mon Sep 17 00:00:00 2001 From: "paul.baranowski" Date: Wed, 15 Dec 2010 14:25:42 -0500 Subject: [PATCH] Removed the API directory, all of it has been moved to application/controllers/ApiController.php --- api/api_version.php | 13 -------- api/get_media.php | 47 ---------------------------- api/notify_media_item_start_play.php | 37 ---------------------- api/notify_schedule_group_play.php | 35 --------------------- api/schedule.php | 18 ----------- 5 files changed, 150 deletions(-) delete mode 100644 api/api_version.php delete mode 100644 api/get_media.php delete mode 100644 api/notify_media_item_start_play.php delete mode 100644 api/notify_schedule_group_play.php delete mode 100644 api/schedule.php diff --git a/api/api_version.php b/api/api_version.php deleted file mode 100644 index 350f477d9..000000000 --- a/api/api_version.php +++ /dev/null @@ -1,13 +0,0 @@ -CAMPCASTER_VERSION)); -?> \ No newline at end of file diff --git a/api/get_media.php b/api/get_media.php deleted file mode 100644 index 0ae512bbc..000000000 --- a/api/get_media.php +++ /dev/null @@ -1,47 +0,0 @@ -getRealFilePath(); - if(!is_file($filepath)) - { - header($_SERVER["SERVER_PROTOCOL"]." 404 Not Found"); - //print 'Ressource in database, but not in storage. Sorry.'; - exit; - } - - // !! binary mode !! - $fp = fopen($filepath, 'rb'); - - header("Content-Type: audio/mpeg"); - header("Content-Length: " . filesize($filepath)); - - fpassthru($fp); - } - else { - header($_SERVER["SERVER_PROTOCOL"]." 404 Not Found"); - exit; - } -} else { - header($_SERVER["SERVER_PROTOCOL"]." 404 Not Found"); - exit; -} -exit; - -?> \ No newline at end of file diff --git a/api/notify_media_item_start_play.php b/api/notify_media_item_start_play.php deleted file mode 100644 index 6a415fbff..000000000 --- a/api/notify_media_item_start_play.php +++ /dev/null @@ -1,37 +0,0 @@ -exists()) { - $result = $sg->notifyMediaItemStartPlay($f->getId()); - if (!PEAR::isError($result)) { - echo json_encode(array("status"=>1, "message"=>"")); - exit; - } else { - echo json_encode(array("status"=>0, "message"=>"DB Error:".$result->getMessage())); - exit; - } - } else { - echo json_encode(array("status"=>0, "message"=>"Schedule group does not exist: ".$schedule_group_id)); - exit; - } -} else { - echo json_encode(array("status"=>0, "message" => "Incorrect or non-numeric arguments given.")); -} -?> \ No newline at end of file diff --git a/api/notify_schedule_group_play.php b/api/notify_schedule_group_play.php deleted file mode 100644 index 7527892bb..000000000 --- a/api/notify_schedule_group_play.php +++ /dev/null @@ -1,35 +0,0 @@ -exists()) { - $result = $sg->notifyGroupStartPlay(); - if (!PEAR::isError($result)) { - echo json_encode(array("status"=>1, "message"=>"")); - exit; - } else { - echo json_encode(array("status"=>0, "message"=>"DB Error:".$result->getMessage())); - exit; - } - } else { - echo json_encode(array("status"=>0, "message"=>"Schedule group does not exist: ".$schedule_group_id)); - exit; - } -} else { - echo json_encode(array("status"=>0, "message"=>"Incorrect or non-numeric arguments given.")); - exit; -} -?> \ No newline at end of file diff --git a/api/schedule.php b/api/schedule.php deleted file mode 100644 index 2009cf4d8..000000000 --- a/api/schedule.php +++ /dev/null @@ -1,18 +0,0 @@ - \ No newline at end of file