diff --git a/footer.html b/footer.html new file mode 100644 index 0000000..40ded81 --- /dev/null +++ b/footer.html @@ -0,0 +1,3 @@ + diff --git a/header.html b/header.html new file mode 100644 index 0000000..cbefdf4 --- /dev/null +++ b/header.html @@ -0,0 +1,10 @@ +
+ +
diff --git a/index.html b/index.html index 316671c..72b3934 100644 --- a/index.html +++ b/index.html @@ -4,22 +4,16 @@ + -
- -
+
-Junior-Doctor Chokai Academy +Junior-Doctor Chokai Academy

ジュニアドクター鳥海塾

近日募集開始

+ diff --git a/jdinit.js b/jdinit.js new file mode 100644 index 0000000..f14c467 --- /dev/null +++ b/jdinit.js @@ -0,0 +1,25 @@ +/* + * include id-specified html into corresponding div + */ +window.addEventListener( +"DOMContentLoaded", +function () { + function includeIdFiles() { + for (let id of ["header", "footer"]) { + let e = document.getElementById(id), + fn = e.id + ".html"; + fetch(fn).then((resp) => { + resp.text().then((text) => { + let newmenu = e.insertAdjacentHTML("afterend", text); + e.remove(); + newmenu.id = id; + }); + }); + + } + } + function init() { + includeIdFiles(); + } + init(); +}); diff --git a/jdmain.css b/jdmain.css index acce1d0..dcedeca 100644 --- a/jdmain.css +++ b/jdmain.css @@ -56,6 +56,10 @@ header ul li{ list-style: none; } +footer { /* XXX: Change ME! */ + border-top: 1px dashed #888; + text-align: right; font-size: 70%; +} div{ width: 100%;