14 |
} |
} |
15 |
|
|
16 |
function newXmlHttp() { |
function newXmlHttp() { |
17 |
try { return new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) {} |
var xhr = null; |
18 |
try { return new ActiveXObject("Microsoft.XMLHTTP"); } catch (e) {} |
try { xhr = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { |
19 |
try { return new XMLHttpRequest(); } catch(e) {} |
try { xhr = new ActiveXObject("Microsoft.XMLHTTP"); } catch (e) { |
20 |
return null; |
try { xhr = new XMLHttpRequest(); } catch(e) { return false } |
21 |
|
} |
22 |
|
} |
23 |
|
return xhr; |
24 |
} |
} |
25 |
|
|
26 |
function startstream() { |
function startstream() { |
42 |
} |
} |
43 |
} |
} |
44 |
streamreq.send(null); |
streamreq.send(null); |
45 |
|
parent.Meteor.lastrequest = parent.Meteor.time(); |
46 |
} |
} |
47 |
|
|
48 |
function extractEvents(responsestr) { |
function extractEvents(responsestr) { |
54 |
y = newdata.indexOf("</"+"script>", x); |
y = newdata.indexOf("</"+"script>", x); |
55 |
if (y != -1) { |
if (y != -1) { |
56 |
eval(newdata.substring((x+8),y)); |
eval(newdata.substring((x+8),y)); |
57 |
|
if (typeof newdata == 'undefined') break; // If message was eof() then we're now in a freed script |
58 |
newdata = newdata.substring(y+9); |
newdata = newdata.substring(y+9); |
59 |
} else { |
} else { |
60 |
|
|
69 |
} |
} |
70 |
} |
} |
71 |
|
|
72 |
|
window.onload = function() { |
73 |
|
if (parent.Meteor.status == 4) startstream(); |
74 |
startstream(); |
} |
75 |
</script> |
</script> |
76 |
</body> |
</body> |
77 |
</html> |
</html> |