[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r15373 - gauger/bindings/js
From: |
gnunet |
Subject: |
[GNUnet-SVN] r15373 - gauger/bindings/js |
Date: |
Wed, 1 Jun 2011 04:19:52 +0200 |
Author: bartpolot
Date: 2011-06-01 04:19:52 +0200 (Wed, 01 Jun 2011)
New Revision: 15373
Modified:
gauger/bindings/js/gauger.js
Log:
Added name escaping for js
Modified: gauger/bindings/js/gauger.js
===================================================================
--- gauger/bindings/js/gauger.js 2011-05-31 18:59:38 UTC (rev 15372)
+++ gauger/bindings/js/gauger.js 2011-06-01 02:19:52 UTC (rev 15373)
@@ -9,6 +9,10 @@
return null;
}
+function GAUGER_ESCAPE(s) {
+ s = s.replace('__', '__-');
+ return s.replace('::', '::-');
+}
function GAUGER(category, name, value, unit, rev) {
host = GAUGER_READ_COOKIE('gauger_host');
@@ -16,7 +20,7 @@
console.log("WARNING: gauger cookie not present. Register browser with
your gauger installation to use the logging funtion.");
return;
}
- name = category + ":::" + name + "___" + unit;
+ name = GAUGER_ESCAPE(category) + ":::" + GAUGER_ESCAPE(name) + "___" +
GAUGER_ESCAPE(unit);
url = unescape(GAUGER_READ_COOKIE('gauger_url'));
url += 'hosts/' + host;
var client = new XMLHttpRequest();
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r15373 - gauger/bindings/js,
gnunet <=