diff options
| author | blob8108 <spaaam42@gmail.com> | 2014-01-06 11:17:59 +0000 |
|---|---|---|
| committer | blob8108 <spaaam42@gmail.com> | 2014-01-06 11:17:59 +0000 |
| commit | c947a4d5b741b783ebe6653929051ea03c34a590 (patch) | |
| tree | 1dd7159b31b8ec85c86ce5d9531e3c7b3644b022 /threads.js | |
| parent | e9020b4ed3f7190dc78e622fbe3b2665e227c30f (diff) | |
| download | snap-byow-c947a4d5b741b783ebe6653929051ea03c34a590.tar.gz snap-byow-c947a4d5b741b783ebe6653929051ea03c34a590.zip | |
Add useful headers to HTTP block
Diffstat (limited to 'threads.js')
| -rw-r--r-- | threads.js | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -1730,6 +1730,9 @@ Process.prototype.reportURL = function (url) { if (!this.httpRequest) { this.httpRequest = new XMLHttpRequest(); this.httpRequest.open("GET", 'http://' + url, true); + this.httpRequest.setRequestHeader("X-Requested-With", + "XMLHttpRequest"); + this.httpRequest.setRequestHeader("X-Application", "Snap! 4.0"); this.httpRequest.send(null); } else if (this.httpRequest.readyState === 4) { response = this.httpRequest.responseText; |
