Commit 7ab7e900ad2c63854d04230287056393f73cd8c4
1 parent
5da68a4a
file function added
Showing
1 changed file
with
16 additions
and
0 deletions
Show diff stats
js/crep.js
1 | +function file(fichier) | |
2 | +{ | |
3 | + if(window.XMLHttpRequest) | |
4 | + xhr_object = new XMLHttpRequest(); | |
5 | + else if(window.ActiveXObject) | |
6 | + xhr_object = new ActiveXObject("Microsoft.XMLHTTP"); | |
7 | + else | |
8 | + return(false); | |
9 | + xhr_object.open("GET", fichier, false); | |
10 | + xhr_object.send(null); | |
11 | + if(xhr_object.readyState == 4) | |
12 | + return(xhr_object.responseText); | |
13 | + else | |
14 | + return(false); | |
15 | +} | |
16 | + | |
1 | 17 | function loadNewDoc(doc) |
2 | 18 | { |
3 | 19 | $("#mainContainer").html(file(doc)); | ... | ... |