summaryrefslogtreecommitdiff
path: root/functions.js
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2006-05-23 07:32:22 +0100
committerAndrew Dolgov <[email protected]>2006-05-23 07:32:22 +0100
commite8bd0da9526712b6a2baa453133380608cd57af6 (patch)
tree9d3a658f58248049153c0f42e19d1390ed1f6cef /functions.js
parent33d13e72e28bf5fd1b8946c69ef05bd0f8ff9d0c (diff)
get rid of vf_hreadf cookie, move data to init-param
Diffstat (limited to 'functions.js')
-rw-r--r--functions.js12
1 files changed, 7 insertions, 5 deletions
diff --git a/functions.js b/functions.js
index da5d95143..58d50eea9 100644
--- a/functions.js
+++ b/functions.js
@@ -783,7 +783,7 @@ function getRelativeFeedId(list, id, direction, unread_only) {
}
} else if (child.id.match("FEEDR-")) {
- if (getCookie("ttrss_vf_hreadf") == 1) {
+ if (getInitParam("hide_read_feeds") == 1) {
if (child.className != "feed") {
alert(child.className);
return child.id.replace('FEEDR-', '');
@@ -798,7 +798,7 @@ function getRelativeFeedId(list, id, direction, unread_only) {
var feed = list.ownerDocument.getElementById("FEEDR-" + getActiveFeedId());
- if (getCookie("ttrss_vf_hreadf") == 1) {
+ if (getInitParam("hide_read_feeds") == 1) {
unread_only = true;
}
@@ -1098,11 +1098,13 @@ function getInitParam(key) {
}
// TODO: batch mode
-function storeInitParam(key, value) {
+function storeInitParam(key, value, is_client) {
try {
getMainContext().init_params[key] = value;
- new Ajax.Request("backend.php?op=rpc&subop=storeParam&key=" +
- param_escape(key) + "&value=" + param_escape(value));
+ if (!is_client) {
+ new Ajax.Request("backend.php?op=rpc&subop=storeParam&key=" +
+ param_escape(key) + "&value=" + param_escape(value));
+ }
} catch (e) {
exception_error("storeInitParam", e);
}