diff options
author | Andrew Dolgov <[email protected]> | 2013-05-07 15:36:14 +0400 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2013-05-07 15:36:14 +0400 |
commit | 82076ce53113be9cc053f8740356e7e1b81e5643 (patch) | |
tree | 5eba36805f593ec7dd0aad671b5bcca0ae01cf53 /prefs.php | |
parent | 66af65f14b4f3c670bb3f9ca7b1c80081f9281d1 (diff) | |
parent | 23923fb29b345c1eea5b70a6df4d30395425bf37 (diff) |
Merge branch 'master' into css-feedtree-counter
Conflicts:
tt-rss.css
Diffstat (limited to 'prefs.php')
-rw-r--r-- | prefs.php | 36 |
1 files changed, 16 insertions, 20 deletions
@@ -12,6 +12,7 @@ exit; } + require_once "autoload.php"; require_once "sessions.php"; require_once "functions.php"; require_once "sanity_check.php"; @@ -19,13 +20,9 @@ require_once "config.php"; require_once "db-prefs.php"; - $link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME); + if (!init_plugins()) return; - if (!init_connection($link)) return; - - login_sequence($link); - - no_cache_incantation(); + login_sequence(); header('Content-Type: text/html; charset=utf-8'); ?> @@ -35,19 +32,19 @@ <head> <title>Tiny Tiny RSS : <?php echo __("Preferences") ?></title> - <?php echo stylesheet_tag("lib/dijit/themes/claro/claro.css"); ?> - <?php echo stylesheet_tag("tt-rss.css"); ?> - <?php echo stylesheet_tag("prefs.css"); ?> + <?php stylesheet_tag("lib/dijit/themes/claro/claro.css"); ?> + <?php stylesheet_tag("tt-rss.css"); ?> + <?php stylesheet_tag("prefs.css"); ?> <?php if ($_SESSION["uid"]) { - $theme = get_pref($link, "USER_CSS_THEME", $_SESSION["uid"], false); + $theme = get_pref( "USER_CSS_THEME", $_SESSION["uid"], false); if ($theme) { - echo stylesheet_tag("themes/$theme"); + stylesheet_tag("themes/$theme"); } } ?> - <?php print_user_stylesheet($link) ?> + <?php print_user_stylesheet() ?> <link rel="shortcut icon" type="image/png" href="images/favicon.png"/> <link rel="icon" type="image/png" sizes="72x72" href="images/favicon-72px.png" /> @@ -61,7 +58,7 @@ "lib/dojo/tt-rss-layer.js", "errors.php?mode=js") as $jsfile) { - echo javascript_tag($jsfile); + javascript_tag($jsfile); } ?> @@ -69,9 +66,7 @@ <?php require 'lib/jshrink/Minifier.php'; - global $pluginhost; - - foreach ($pluginhost->get_plugins() as $n => $p) { + foreach (PluginHost::getInstance()->get_plugins() as $n => $p) { if (method_exists($p, "get_prefs_js")) { echo JShrink\Minifier::minify($p->get_prefs_js()); } @@ -95,7 +90,7 @@ <body id="ttrssPrefs" class="claro"> -<div id="notify" class="notify"><span id="notify_body"> </span></div> +<div id="notify" class="notify" style="display : none"></div> <div id="cmdline" style="display : none"></div> <div id="overlay"> @@ -132,9 +127,12 @@ <div id="userConfigTab" dojoType="dijit.layout.ContentPane" href="backend.php?op=pref-users" title="<?php echo __('Users') ?>"></div> + <div id="systemConfigTab" dojoType="dijit.layout.ContentPane" + href="backend.php?op=pref-system" + title="<?php echo __('System') ?>"></div> <?php } ?> <?php - $pluginhost->run_hooks($pluginhost::HOOK_PREFS_TABS, + PluginHost::getInstance()->run_hooks(PluginHost::HOOK_PREFS_TABS, "hook_prefs_tabs", false); ?> </div> @@ -152,7 +150,5 @@ </div> -<?php db_close($link); ?> - </body> </html> |