예제 #1
0
파일: index.php 프로젝트: uplight/gallery
        header('Content-type: application/json');
        $out->data = json_decode(file_get_contents('data/d1920.json'));
        $out->result = 'success';
        $out->type = 'settings';
        $result = json_encode($out);
        break;
    case 'data':
        include 'cl/DbConnector.php';
        $ctr = new DbConnector();
        $result = json_encode($ctr->process($a, $data, $opt));
        header('Content-type: application/json');
        break;
    case 'get_all_data':
        include 'cl/DbConnector.php';
        $ctr = new DbConnector();
        $result = json_encode($ctr->getAllData());
        header('Content-type: application/json');
        break;
    case 'screen':
        include 'cl/Screen.php';
        $ctr = new Screen();
        $result = $ctr->process($a, $data);
        break;
    case 'login':
        include 'gateway.php';
        exit;
        break;
}
if ($result) {
    echo $result;
} else {