summaryrefslogtreecommitdiff
path: root/prefs.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2005-11-17 08:25:29 +0100
committerAndrew Dolgov <[email protected]>2005-11-17 08:25:29 +0100
commitab49d368c198a42e1c38e4091afc16601a44374f (patch)
tree2973fa9aa4879d80d95f5ce56a61db303a7ab6fd /prefs.php
parent7268adf7bd4045643e7a4085263e9b80c062b24c (diff)
made prefs.php aware of compact stylesheet, close db link at the end of prefs.php and tt-rss.php
Diffstat (limited to 'prefs.php')
-rw-r--r--prefs.php29
1 files changed, 21 insertions, 8 deletions
diff --git a/prefs.php b/prefs.php
index a2e7ac31c..b4d7922d2 100644
--- a/prefs.php
+++ b/prefs.php
@@ -1,7 +1,27 @@
+<?
+ require_once "version.php";
+ require_once "config.php";
+ require_once "db-prefs.php";
+
+ $link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME);
+?>
<html>
<head>
<title>Tiny Tiny RSS : Preferences</title>
<link rel="stylesheet" href="tt-rss.css" type="text/css">
+
+ <? if (get_pref($link, 'USE_COMPACT_STYLESHEET')) { ?>
+
+ <link rel="stylesheet" href="tt-rss_compact.css" type="text/css">
+
+ <? } else { ?>
+
+ <link title="Compact Stylesheet" rel="alternate stylesheet"
+ type="text/css" href="tt-rss_compact.css"/>
+
+ <? } ?>
+
+
<script type="text/javascript" src="functions.js"></script>
<script type="text/javascript" src="prefs.js"></script>
@@ -13,14 +33,6 @@
<body onload="init()">
-<?
- require_once "version.php";
- require_once "config.php";
- require_once "db-prefs.php";
-
- $link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME);
-?>
-
<table width="100%" height="100%" cellspacing="0" cellpadding="0" class="main">
<? if (get_pref($link, 'DISPLAY_HEADER')) { ?>
<tr>
@@ -72,6 +84,7 @@
<? } ?>
</table>
+<? db_close($link); ?>
</body>
</html>