From: Andrew Dolgov Date: Sat, 20 May 2006 12:51:39 +0000 (+0100) Subject: feed cat editor uses prototype X-Git-Tag: 1.2.0~56 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=0666e120e8915920070dc18273cd67787484f103;p=tt-rss.git feed cat editor uses prototype --- diff --git a/backend.php b/backend.php index 267cc7dc..d203af3f 100644 --- a/backend.php +++ b/backend.php @@ -1982,6 +1982,8 @@ if (db_num_rows($result) != 0) { + print "
"; + print "

"; @@ -2005,9 +2007,13 @@ $edit_cat_id = $_GET["id"]; - if ($subop == "editCat" && $cat_id != $edit_cat_id) { - $class .= "Grayed"; - $this_row_id = ""; + if ($subop == "editCat") { + if ($cat_id != $edit_cat_id) { + $class .= "Grayed"; + $this_row_id = ""; + } else { + $class .= "Selected"; + } } else { $this_row_id = "id=\"FCATR-$cat_id\""; } @@ -2026,16 +2032,22 @@ } else if ($cat_id != $edit_cat_id) { - print ""; print ""; } else { - print ""; + print ""; - print ""; + print ""; } @@ -2045,15 +2057,17 @@ } print "
$edit_title"; + + print ""; + print ""; + print ""; + + print "
"; + + print "

"; print "

"; if ($subop == "editCat") { print "Edit category:  + onclick=\"javascript:feedCatEditSave()\" value=\"Save\"> "; + onclick=\"javascript:feedCatEditCancel()\" value=\"Cancel\">"; } else { print " diff --git a/prefs.js b/prefs.js index ec65e839..c98dbcc8 100644 --- a/prefs.js +++ b/prefs.js @@ -719,11 +719,11 @@ function feedCatEditSave() { notify("Saving category..."); - var cat_title = document.getElementById("iedit_title").value; +// var cat_title = document.getElementById("iedit_title").value; - xmlhttp.open("GET", "backend.php?op=pref-feeds&subop=saveCat&id=" + - param_escape(active_feed_cat) + "&title=" + param_escape(cat_title), - true); + var query = Form.serialize("feed_cat_edit_form"); + + xmlhttp.open("GET", "backend.php?" + query, true); xmlhttp.onreadystatechange=feedlist_callback; xmlhttp.send(null); diff --git a/tt-rss.css b/tt-rss.css index f9e109df..a5977973 100644 --- a/tt-rss.css +++ b/tt-rss.css @@ -287,11 +287,15 @@ a:hover { background-color : #f0fff0; } -.iedit { +input.iedit { width : 100%; padding-left : 2px; } +select.iedit { + width : 100%; +} + input.editbox { width : 200px; padding-left : 2px;