From: Andrew Dolgov Date: Sat, 26 Nov 2005 06:36:23 +0000 (+0100) Subject: theme select box X-Git-Tag: schema_feature_freeze_for_1.1~82 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=58f8ad544e5c7f65e5f91b56cc799fd430f120b2;p=tt-rss.git theme select box --- diff --git a/backend.php b/backend.php index 3a07a0f2..fa3be8dc 100644 --- a/backend.php +++ b/backend.php @@ -2249,6 +2249,22 @@ header("Location: prefs.php"); + } else if ($subop == "Change theme") { + + $theme = db_escape_string($_POST["theme"]); + + if ($theme == "Default") { + $theme_qpart = 'NULL'; + } else { + $theme_qpart = "'$theme'"; + } + + db_query($link, "UPDATE ttrss_users SET + theme_id = (SELECT id FROM ttrss_themes WHERE + theme_name = '$theme') WHERE id = " . $_SESSION["uid"]); + + header("Location: prefs.php"); + } else { if (!SINGLE_USER_MODE) { @@ -2316,6 +2332,44 @@ } + print "
"; + + print ""; + print ""; + + print ""; + + print ""; + print "

Themes

Select theme
"; + print ""; + print "

"; + print "

"; + $result = db_query($link, "SELECT ttrss_user_prefs.pref_name,short_desc,help_text,value,type_name, section_name,def_value