accept more headers from robots
@@ -2,6 +2,15 @@
2
2
require_once __DIR__ . '/folderNode.php';
3
3
4
4
header('Content-Type: application/json; charset=utf-8');
5
header('Access-Control-Allow-Origin: *');
6
header('Access-Control-Allow-Methods: GET, HEAD, OPTIONS');
7
header('Access-Control-Allow-Headers: *');
8
header('X-Robots-Tag: all');
9
10
if (isset($_SERVER['REQUEST_METHOD']) && $_SERVER['REQUEST_METHOD'] === 'OPTIONS') {
11
http_response_code(204);
12
exit;
13
}
5
14
6
15
$dataRoot = __DIR__ . DIRECTORY_SEPARATOR . 'data';
7
16
$chaptersRoot = $dataRoot . DIRECTORY_SEPARATOR . 'chapters';
@@ -2,6 +2,15 @@2
require_once __DIR__ . '/folderNode.php';2
require_once __DIR__ . '/folderNode.php';3
3
4
header('Content-Type: application/json; charset=utf-8');4
header('Content-Type: application/json; charset=utf-8');5
header('Access-Control-Allow-Origin: *');6
header('Access-Control-Allow-Methods: GET, HEAD, OPTIONS');7
header('Access-Control-Allow-Headers: *');8
header('X-Robots-Tag: all');9
10
if (isset($_SERVER['REQUEST_METHOD']) && $_SERVER['REQUEST_METHOD'] === 'OPTIONS') {11
http_response_code(204);12
exit;13
}5
14
6
$dataRoot = __DIR__ . DIRECTORY_SEPARATOR . 'data';15
$dataRoot = __DIR__ . DIRECTORY_SEPARATOR . 'data';7
$chaptersRoot = $dataRoot . DIRECTORY_SEPARATOR . 'chapters';16
$chaptersRoot = $dataRoot . DIRECTORY_SEPARATOR . 'chapters';