forked from SouICry/fetch
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfilemerger.html
More file actions
30 lines (29 loc) · 990 Bytes
/
filemerger.html
File metadata and controls
30 lines (29 loc) · 990 Bytes
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
<body>
</body>
<script src="js/pages.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"></script>
<script>
var pageContent = "";
function loadPage(pageName, row, column) {
$.ajax({
type: "POST",
url: "/loadPage",
data: {name: pageName},
async: false,
success: function (data) {
pageContent += "<div><div id='" + pageName +
"' data-x='" + column + "' data-y='" + row + "'>" + data + "</div></div>";
}
});
}
for (var j = 0; j < allPages.length; j++) {
pageContent += '<div id="section-' + j + '">';
for (var i = 0; i < allPages[j].length; i++) {
var whichid = allPages[j][i];
console.log(allPages[j][i]);
loadPage(whichid, j, i);
}
pageContent += '</div>';
}
$('body').append(pageContent);
</script>