The clean & modern RSS server that doesn't give you any crap. https://thearsse.com/
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

35 рядки
1.1 KiB

<?php
/** @license MIT
* Copyright 2017 J. King, Dustin Wilson et al.
* See LICENSE and AUTHORS files for details */
4 роки тому
declare(strict_types=1);
3 роки тому
namespace JKingWeb\Arsse;
7 роки тому
const BASE = __DIR__.DIRECTORY_SEPARATOR;
const NS_BASE = __NAMESPACE__."\\";
require_once BASE."vendor".DIRECTORY_SEPARATOR."autoload.php";
ignore_user_abort(true);
ini_set("memory_limit", "-1");
ini_set("max_execution_time", "0");
// NOTE: While running in the wild we don't want to spew deprecation warnings if users are ahead of us in PHP versions
error_reporting(\E_ALL & ~\E_DEPRECATED);
if (\PHP_SAPI === "cli") {
3 роки тому
// initialize the CLI; this automatically handles --help and --version else
3 роки тому
Arsse::$obj = new Factory;
$cli = new CLI;
// handle other CLI requests; some do not require configuration
$exitStatus = $cli->dispatch();
exit($exitStatus);
} else {
// load configuration
3 роки тому
Arsse::bootstrap();
// handle Web requests
$emitter = new \Laminas\HttpHandlerRunner\Emitter\SapiEmitter;
$response = (new REST)->dispatch();
$emitter->emit($response);
7 роки тому
}