]> git.wh0rd.org - tt-rss.git/blob - functions.js
feed editor, xmlhttp locking in preferences, try to initialize xmlhttp_rpc via Active...
[tt-rss.git] / functions.js
1 function param_escape(arg) {
2 if (typeof encodeURIComponent != 'undefined')
3 return encodeURIComponent(arg);
4 else
5 return escape(arg);
6 }
7
8 function param_unescape(arg) {
9 if (typeof decodeURIComponent != 'undefined')
10 return decodeURIComponent(arg);
11 else
12 return unescape(arg);
13 }
14
15 function delay(gap) {
16 var then,now;
17 then=new Date().getTime();
18 now=then;
19 while((now-then)<gap) {
20 now=new Date().getTime();
21 }
22 }
23
24 function notify(msg) {
25
26 var n = document.getElementById("notify");
27
28 n.innerHTML = msg;
29
30 if (msg.length == 0) {
31 n.style.display = "none";
32 } else {
33 n.style.display = "block";
34 }
35
36 }
37
38 function printLockingError() {
39 notify("Please wait until operation finishes");
40 }
41
42