footer: add footer loader

This commit is contained in:
2026-06-03 03:42:39 +07:00
parent b7c10621b1
commit 42429b1509
29 changed files with 39 additions and 101 deletions
@@ -493,6 +493,7 @@
<div id="footer"></div>
<script src="components/header/headerLoader.js"></script>
<script src="newsPages/newsArticle1/newsArticle1.js"></script>
<script src="/components/footer/footerLoader.js"></script>
<script src="newsPages/newsArticle1/newsArticle1.js?v=1.0"></script>
</body>
</html>
@@ -1,7 +1 @@
////views\newsPages\newsArticle1\newsArticle1.js
// Load footer
fetch("components/footer/footer.html")
.then((response) => response.text())
.then((data) => {
document.getElementById("footer").innerHTML = data;
});