X-Git-Url: https://git.wh0rd.org/?a=blobdiff_plain;f=index.php;h=74498b8f45a7f4a3b1ee47feeba2d74422d03674;hb=a08e2e4d9358dc7b1bd8f4b360d83e1d7e5fc8e8;hp=d9363644c8e4b6455e325b701dacb4e14ed1180d;hpb=c8b693cf7f8616e4dc37ee2f370a01b6642ac7f5;p=tt-rss.git diff --git a/index.php b/index.php index d9363644..74498b8f 100644 --- a/index.php +++ b/index.php @@ -19,6 +19,7 @@ set_include_path(dirname(__FILE__) ."/include" . PATH_SEPARATOR . get_include_path()); + require_once "autoload.php"; require_once "sessions.php"; require_once "functions.php"; require_once "sanity_check.php"; @@ -29,28 +30,22 @@ $mobile = new Mobile_Detect(); - $link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME); - - if (!init_connection($link)) return; - - global $pluginhost; + if (!init_plugins()) return; if (!$_REQUEST['mobile']) { - if ($mobile->isTablet() && $pluginhost->get_plugin("digest")) { + if ($mobile->isTablet() && PluginHost::getInstance()->get_plugin("digest")) { header('Location: backend.php?op=digest'); exit; - } else if ($mobile->isMobile() && $pluginhost->get_plugin("mobile")) { + } else if ($mobile->isMobile() && PluginHost::getInstance()->get_plugin("mobile")) { header('Location: backend.php?op=mobile'); exit; - } else if ($mobile->isMobile() && $pluginhost->get_plugin("digest")) { + } else if ($mobile->isMobile() && PluginHost::getInstance()->get_plugin("digest")) { header('Location: backend.php?op=digest'); exit; } } - login_sequence($link); - - no_cache_incantation(); + login_sequence(); header('Content-Type: text/html; charset=utf-8'); @@ -61,23 +56,28 @@ Tiny Tiny RSS + + - - + - +