remove includeHTML
This commit is contained in:
parent
9cb1b36afd
commit
71aea24d02
2 changed files with 0 additions and 19 deletions
|
@ -1,18 +0,0 @@
|
|||
let z = document.getElementsByTagName("*");
|
||||
|
||||
for (let i = 0; i < z.length; i++) {
|
||||
let element = z[i];
|
||||
let externalFileURL = element.getAttribute("includeHTML");
|
||||
if (externalFileURL) {
|
||||
let xhr = new XMLHttpRequest();
|
||||
xhr.onreadystatechange = function() {
|
||||
if (this.readyState == 4) {
|
||||
if (this.status == 200) { element.innerHTML = this.responseText; }
|
||||
if (this.status == 404) { element.innerHTML = "Page not found."; }
|
||||
element.removeAttribute("includeHTML");
|
||||
}
|
||||
}
|
||||
xhr.open("GET", externalFileURL, true);
|
||||
xhr.send();
|
||||
}
|
||||
}
|
|
@ -2,7 +2,6 @@ require("./browserCheck");
|
|||
|
||||
require("./error");
|
||||
require("./imgPreview");
|
||||
require("./includeHTML");
|
||||
require("./viewPost");
|
||||
require("./externalLinkHandler");
|
||||
require("./prism");
|
||||
|
|
Loading…
Reference in a new issue