diff options
author | Andrew Dolgov <[email protected]> | 2007-01-24 09:43:30 +0100 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2007-01-24 09:43:30 +0100 |
commit | 4220d6b0374682f03e5c2195799ed1cbce8f3cc3 (patch) | |
tree | 521f34ca90ee8c2950c83e6637d6d9e4e7621eba | |
parent | eb28b131bc2d7354252f61849551a20b617bd5e4 (diff) |
store navigator.appName in session object on init
-rw-r--r-- | functions.php | 4 | ||||
-rw-r--r-- | modules/backend-rpc.php | 4 | ||||
-rw-r--r-- | tt-rss.js | 4 |
3 files changed, 10 insertions, 2 deletions
diff --git a/functions.php b/functions.php index 0b3f7ba9f..4fadff8d9 100644 --- a/functions.php +++ b/functions.php @@ -1348,7 +1348,7 @@ return false; } else { return true; - } + } } function file_is_locked($filename) { @@ -2742,6 +2742,8 @@ } + print '[' . $_SESSION["client.userAgent"] . ']'; + print "<td class=\"headlineActions$rtl_cpart\"> <ul class=\"headlineDropdownMenu\"> <li class=\"top2\"> diff --git a/modules/backend-rpc.php b/modules/backend-rpc.php index 1a019af5b..b6823e2b7 100644 --- a/modules/backend-rpc.php +++ b/modules/backend-rpc.php @@ -185,6 +185,10 @@ print "<error error-code=\"0\"/>"; print_init_params($link); print_runtime_info($link); + + # assign client-passed params to session + $_SESSION["client.userAgent"] = $_GET["ua"]; + } print "</rpc-reply>"; } @@ -364,7 +364,9 @@ function init() { debug('debug mode activated'); } - xmlhttp.open("GET", "backend.php?op=rpc&subop=sanityCheck", true); + var params = "&ua=" + param_escape(navigator.userAgent); + + xmlhttp.open("GET", "backend.php?op=rpc&subop=sanityCheck" + params, true); xmlhttp.onreadystatechange=backend_sanity_check_callback; xmlhttp.send(null); |