Skip to content

Commit 808924e

Browse files
author
yuangongji
authored
Merge pull request #877 from ygj6/fix874
Add 874 examples
2 parents bde8453 + 0712d38 commit 808924e

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

examples/issues/874/index.html

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<!DOCTYPE html>
2+
<html id="ng-app" ng-app="app">
3+
4+
<head>
5+
<title>Simple example</title>
6+
</head>
7+
8+
<body>
9+
<h1>hello world</h1>
10+
</body>
11+
<script>
12+
var xhr1 = new XMLHttpRequest();
13+
14+
// xhr1.timeout = 10000; // In Internet Explorer, setting xhr.timeout before xhr.open() will report an error
15+
xhr1.ontimeout = function (e) {
16+
console.log(e);
17+
};
18+
19+
xhr1.open("GET", "http://localhost:8080/test", true);
20+
xhr1.timeout = 10000;
21+
xhr1.send(null);
22+
console.log(xhr1.timeout);
23+
</script>
24+
25+
</html>

0 commit comments

Comments
 (0)