From 58f8ad544e5c7f65e5f91b56cc799fd430f120b2 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Sat, 26 Nov 2005 07:36:23 +0100 Subject: [PATCH] theme select box --- backend.php | 54 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) 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 -- 2.39.5