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