aboutsummaryrefslogtreecommitdiff
path: root/Neutron-trunk/api/renderer/main.php
blob: c873f6025a718989bb451e5a1816bdebacf8f8ac (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<?php

global $_VERSION;

global $_FNSN_DUMP_STARTDATE;
$_FNSN_DUMP_STARTDATE = new DateTime("now");
require_once $_SERVER['DOCUMENT_ROOT'] . "/api/engine-cyclic/includes/cache.php";
ob_start();

function rlgps(string $message) {
    file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/engine-cyclic.log", file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/engine-cyclic.log") . "\n" . "... " . $message);
}

if (!file_exists($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/oldRenderer")) {
    $_VERSION = trim(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/api/cyclic_version"));
    $_RENDERER = "Neutron Copper";
    file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/engine-cyclic.log", "Using CyclicCMS version " . $_VERSION);
    require_once $_SERVER['DOCUMENT_ROOT'] . "/api/engine-cyclic/wrapper.php";
} else {
    $_VERSION = trim(file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/api/jaw_version"));
    $_RENDERER = "Neutron Titanium";
    file_put_contents($_SERVER['DOCUMENT_ROOT'] . "/data/webcontent/engine-cyclic.log", "Using JustAWebsite version " . $_VERSION);
    require_once $_SERVER['DOCUMENT_ROOT'] . "/api/engine-jaw/render.php";
}