Commit 7449c7ed authored by Nico Schallehn's avatar Nico Schallehn

Cleanup des Quellcodes

parent 1fbef097
This diff is collapsed.
<?php <?php
/** /**
*
* @author Nico Schallehn, Markus Then * @author Nico Schallehn, Markus Then
* * @license MIT
*/ */
$beginn = microtime(true); $beginn = microtime(true);
header('content-type: application/json; charset=utf-8'); header('content-type: application/json; charset=utf-8');
include 'api.class.php'; include 'api.class.php';
$API = new MediaDBAPI(); $API = new MediaDBAPI();
if($API->APIinit($_GET['key'])){ if($API->APIinit($_GET['key'])){
...@@ -19,12 +17,11 @@ if($API->APIinit($_GET['key'])){ ...@@ -19,12 +17,11 @@ if($API->APIinit($_GET['key'])){
else{ else{
$respons = $API->error(1003); $respons = $API->error(1003);
} }
} }
else { else {
$respons = $API->error(1002); $respons = $API->error(1002);
} }
$Laufzeit = microtime(true) - $beginn; $Laufzeit = microtime(true) - $beginn;
echo json_encode( $API->APIrespons(sprintf('%.5f', $Laufzeit), $respons),(isset($_GET['Pretty'])?JSON_PRETTY_PRINT:0));//,JSON_PRETTY_PRINT echo json_encode( $API->APIrespons(sprintf('%.5f', $Laufzeit), $respons),(isset($_GET['Pretty'])?JSON_PRETTY_PRINT:0));
?> ?>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment