diff options
author | Andrew Dolgov <[email protected]> | 2009-03-21 23:11:58 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2009-03-21 23:11:58 +0300 |
commit | c7e51de137d9b02ce7b9ddabde86f91d4119ce4b (patch) | |
tree | 0b09b4d10bfe7a3834f2aba2ecd093e7547c129e /modules | |
parent | 2b38f79c86ad9199f39fa8efac1c0e89c6f3a465 (diff) |
Revert "update translations"
This reverts commit 2b38f79c86ad9199f39fa8efac1c0e89c6f3a465.
Wrong commit from wrong branch.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/backend-rpc.php | 29 | ||||
-rw-r--r-- | modules/pref-feeds.php | 31 |
2 files changed, 44 insertions, 16 deletions
diff --git a/modules/backend-rpc.php b/modules/backend-rpc.php index afcd82d3f..8b22bf850 100644 --- a/modules/backend-rpc.php +++ b/modules/backend-rpc.php @@ -87,8 +87,9 @@ } if ($subop == "publ") { - $pub = $_GET["pub"]; - $id = db_escape_string($_GET["id"]); + $pub = $_REQUEST["pub"]; + $id = db_escape_string($_REQUEST["id"]); + $note = trim(strip_tags(db_escape_string($_REQUEST["note"]))); if ($pub == "1") { $pub = "true"; @@ -96,18 +97,36 @@ $pub = "false"; } + if ($note != 'undefined') { + $note_qpart = "note = '$note',"; + } + // FIXME this needs collision testing - $result = db_query($link, "UPDATE ttrss_user_entries SET published = $pub + $result = db_query($link, "UPDATE ttrss_user_entries SET + $note_qpart + published = $pub WHERE ref_id = '$id' AND owner_uid = " . $_SESSION["uid"]); - print "<rpc-reply><counters>"; + + print "<rpc-reply>"; + + print "<counters>"; getGlobalCounters($link); getLabelCounters($link); if (get_pref($link, 'ENABLE_FEED_CATS')) { getCategoryCounters($link); } - print "</counters></rpc-reply>"; + print "</counters>"; + + if ($note != 'undefined') { + $note_size = strlen($note); + print "<note id=\"$id\" size=\"$note_size\">"; + print "<![CDATA[" . format_article_note($id, $note) . "]]>"; + print "</note>"; + } + + print "</rpc-reply>"; return; } diff --git a/modules/pref-feeds.php b/modules/pref-feeds.php index fae1fbe2f..36a0e4d32 100644 --- a/modules/pref-feeds.php +++ b/modules/pref-feeds.php @@ -702,8 +702,12 @@ if (file_exists($icons_dir . "/$id.ico")) { unlink($icons_dir . "/$id.ico"); } + + ccache_remove($link, $id, $_SESSION["uid"]); + } else { label_remove($link, -11-$id, $_SESSION["uid"]); + ccache_remove($link, -11-$id, $_SESSION["uid"]); } } } @@ -992,6 +996,9 @@ if ($num_feeds == 0) { db_query($link, "DELETE FROM ttrss_feed_categories WHERE id = '$id' AND owner_uid = " . $_SESSION["uid"]); + + ccache_remove($link, $id, $_SESSION["uid"], true); + } else { print format_warning(__("Unable to delete non empty feed categories.")); @@ -1369,26 +1376,28 @@ print "<select id=\"feedActionChooser\" onchange=\"feedActionChange()\"> <option value=\"facDefault\" selected>".__('Actions...')."</option> - <option disabled>--------</option> - <option style=\"color : #5050aa\" disabled>".__('Selection:')."</option> - <option value=\"facEdit\"> ".__('Edit')."</option>"; + <optgroup label=\"".__('Selection:')."\"> + <option value=\"facEdit\">".__('Edit')."</option>"; if (FORCE_ARTICLE_PURGE == 0) { print - "<option value=\"facPurge\"> ".__('Manual purge')."</option>"; + "<option value=\"facPurge\">".__('Manual purge')."</option>"; } print " - <option value=\"facClear\"> ".__('Clear feed data')."</option> - <option value=\"facRescore\"> ".__('Rescore articles')."</option> - <option value=\"facUnsubscribe\"> ".__('Unsubscribe')."</option>"; + <option value=\"facClear\">".__('Clear feed data')."</option> + <option value=\"facRescore\">".__('Rescore articles')."</option> + <option value=\"facUnsubscribe\">".__('Unsubscribe')."</option>"; + + print "</optgroup>"; if (get_pref($link, 'ENABLE_FEED_CATS')) { - print "<option disabled>--------</option> - <option style=\"color : #5050aa\" disabled>".__('Other:')."</option> - <option value=\"facEditCats\"> ".__('Edit categories')." - </option>"; + print "<optgroup label=\"".__('Other:')."\"> + <option value=\"facEditCats\">".__('Edit categories')." + </option> + </optgroup>"; + } print "</select>"; |