summaryrefslogtreecommitdiff
path: root/backend.php
diff options
context:
space:
mode:
Diffstat (limited to 'backend.php')
-rw-r--r--backend.php22
1 files changed, 15 insertions, 7 deletions
diff --git a/backend.php b/backend.php
index 4645759ea..183cacbcd 100644
--- a/backend.php
+++ b/backend.php
@@ -2427,12 +2427,10 @@
if ($subop == "editSave") {
- $sql_exp = trim($_GET["s"]);
- $descr = trim($_GET["d"]);
+ $sql_exp = trim($_GET["sql_exp"]);
+ $descr = db_escape_string(trim($_GET["description"]));
$label_id = db_escape_string($_GET["id"]);
-// print "$sql_exp : $descr : $label_id";
-
$result = db_query($link, "UPDATE ttrss_labels SET
sql_exp = '$sql_exp',
description = '$descr'
@@ -2486,6 +2484,8 @@
if (db_num_rows($result) != 0) {
+ print "<form id=\"label_edit_form\">";
+
print "<p><table width=\"100%\" cellspacing=\"0\"
class=\"prefLabelList\" id=\"prefLabelList\">";
@@ -2548,12 +2548,18 @@
} else {
- print "<td align='center'><input disabled=\"true\" type=\"checkbox\" checked></td>";
+ print "<td align='center'><input disabled=\"true\" type=\"checkbox\" checked>";
+
+ print "<input type=\"hidden\" name=\"id\" value=\"$label_id\">";
+ print "<input type=\"hidden\" name=\"op\" value=\"pref-labels\">";
+ print "<input type=\"hidden\" name=\"subop\" value=\"editSave\">";
+
+ print "</td>";
- print "<td><input id=\"iedit_expr\" value=\"".$line["sql_exp"].
+ print "<td><input class=\"iedit\" name=\"sql_exp\" value=\"".$line["sql_exp"].
"\"></td>";
- print "<td><input id=\"iedit_descr\" value=\"".$line["description"].
+ print "<td><input class=\"iedit\" name=\"description\" value=\"".$line["description"].
"\"></td>";
}
@@ -2568,6 +2574,8 @@
}
print "</table>";
+
+ print "</form>";
print "<p id=\"labelOpToolbar\">";