]>
Commit | Line | Data |
---|---|---|
1 | <?php | |
2 | set_include_path(dirname(__FILE__) ."/include" . PATH_SEPARATOR . | |
3 | get_include_path()); | |
4 | ||
5 | require_once "sessions.php"; | |
6 | require_once "functions.php"; | |
7 | require_once "sanity_check.php"; | |
8 | require_once "version.php"; | |
9 | require_once "config.php"; | |
10 | require_once "db-prefs.php"; | |
11 | ||
12 | $link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME); | |
13 | ||
14 | if (!init_connection($link)) return; | |
15 | ||
16 | login_sequence($link); | |
17 | ||
18 | no_cache_incantation(); | |
19 | ||
20 | header('Content-Type: text/html; charset=utf-8'); | |
21 | ?> | |
22 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | |
23 | "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | |
24 | <html> | |
25 | <head> | |
26 | <title><?php echo PAGE_TITLE ?> : <?php echo __("Preferences") ?></title> | |
27 | ||
28 | <?php echo stylesheet_tag("lib/dijit/themes/claro/claro.css"); ?> | |
29 | <?php echo stylesheet_tag("tt-rss.css"); ?> | |
30 | ||
31 | <?php print_user_stylesheet($link) ?> | |
32 | ||
33 | <link rel="shortcut icon" type="image/png" href="images/favicon.png"/> | |
34 | <link rel="icon" type="image/png" sizes="72x72" href="images/favicon-72px.png" /> | |
35 | ||
36 | <?php | |
37 | foreach (array("lib/prototype.js", | |
38 | "lib/scriptaculous/scriptaculous.js?load=effects,dragdrop,controls", | |
39 | "lib/dojo/dojo.js", | |
40 | "lib/dijit/dijit.js", | |
41 | "lib/dojo/tt-rss-layer.js", | |
42 | "localized_js.php", | |
43 | "errors.php?mode=js") as $jsfile) { | |
44 | ||
45 | echo javascript_tag($jsfile); | |
46 | ||
47 | } ?> | |
48 | ||
49 | <script type="text/javascript"> | |
50 | <?php | |
51 | require 'lib/jshrink/Minifier.php'; | |
52 | ||
53 | global $pluginhost; | |
54 | ||
55 | foreach ($pluginhost->get_plugins() as $n => $p) { | |
56 | if (method_exists($p, "get_prefs_js")) { | |
57 | echo JShrink\Minifier::minify($p->get_prefs_js()); | |
58 | } | |
59 | } | |
60 | ||
61 | print get_minified_js(array("functions", "deprecated", "prefs")); | |
62 | ||
63 | ?> | |
64 | </script> | |
65 | ||
66 | <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> | |
67 | ||
68 | <script type="text/javascript"> | |
69 | Event.observe(window, 'load', function() { | |
70 | init(); | |
71 | }); | |
72 | </script> | |
73 | ||
74 | </head> | |
75 | ||
76 | <body id="ttrssPrefs" class="claro"> | |
77 | ||
78 | <div id="notify" class="notify"><span id="notify_body"> </span></div> | |
79 | <div id="cmdline" style="display : none"></div> | |
80 | ||
81 | <div id="overlay"> | |
82 | <div id="overlay_inner"> | |
83 | <div class="insensitive"><?php echo __("Loading, please wait...") ?></div> | |
84 | <div dojoType="dijit.ProgressBar" places="0" style="width : 300px" id="loading_bar" | |
85 | progress="0" maximum="100"> | |
86 | </div> | |
87 | <noscript><br/><?php print_error('Javascript is disabled. Please enable it.') ?></noscript> | |
88 | </div> | |
89 | </div> | |
90 | ||
91 | <img id="piggie" src="images/piggie.png" style="display : none" alt="piggie"/> | |
92 | ||
93 | <div id="header" dojoType="dijit.layout.ContentPane" region="top"> | |
94 | <!-- <a href='#' onclick="showHelp()"><?php echo __("Keyboard shortcuts") ?></a> | --> | |
95 | <a href="#" onclick="gotoMain()"><?php echo __('Exit preferences') ?></a> | |
96 | </div> | |
97 | ||
98 | <div id="main" dojoType="dijit.layout.BorderContainer"> | |
99 | ||
100 | <div dojoType="dijit.layout.TabContainer" region="center" id="pref-tabs"> | |
101 | <div id="genConfigTab" dojoType="dijit.layout.ContentPane" | |
102 | href="backend.php?op=pref-prefs" | |
103 | title="<?php echo __('Preferences') ?>"></div> | |
104 | <div id="feedConfigTab" dojoType="dijit.layout.ContentPane" | |
105 | href="backend.php?op=pref-feeds" | |
106 | title="<?php echo __('Feeds') ?>"></div> | |
107 | <div id="filterConfigTab" dojoType="dijit.layout.ContentPane" | |
108 | href="backend.php?op=pref-filters" | |
109 | title="<?php echo __('Filters') ?>"></div> | |
110 | <div id="labelConfigTab" dojoType="dijit.layout.ContentPane" | |
111 | href="backend.php?op=pref-labels" | |
112 | title="<?php echo __('Labels') ?>"></div> | |
113 | <?php if ($_SESSION["access_level"] >= 10) { ?> | |
114 | <div id="userConfigTab" dojoType="dijit.layout.ContentPane" | |
115 | href="backend.php?op=pref-users" | |
116 | title="<?php echo __('Users') ?>"></div> | |
117 | <?php } ?> | |
118 | <?php | |
119 | $pluginhost->run_hooks($pluginhost::HOOK_PREFS_TABS, | |
120 | "hook_prefs_tabs", false); | |
121 | ?> | |
122 | </div> | |
123 | ||
124 | <div id="footer" dojoType="dijit.layout.ContentPane" region="bottom"> | |
125 | <a class="insensitive" target="_blank" href="http://tt-rss.org/"> | |
126 | Tiny Tiny RSS</a> © 2005-<?php echo date('Y') ?> | |
127 | <a class="insensitive" target="_blank" | |
128 | href="http://fakecake.org/">Andrew Dolgov</a> | |
129 | </div> <!-- footer --> | |
130 | ||
131 | </div> | |
132 | ||
133 | <?php db_close($link); ?> | |
134 | ||
135 | </body> | |
136 | </html> |