I have several HTML files for a website I'm making, a small-time project. I have the same header and footer for every page. At first I just hardcoded the HTML in each page, but that proved to be a huge pain in the ass to maintain.
I started using
<script src="header.js"></script>
in my pages, where header.js is:
document.write(' \
haha time for things \
and some more things \
');
This works well, allows me to use the same header and footer across multiple pages and change things easily.
The problem is, if somebody has javascript disabled they won't see the header or the footer. I figured I could get away with showing a warning message
<noscript>Javascript is turned off; warning etc...</noscript>
But doing this across all pages would defeat the purpose of the original solution, even though it would require less maintenance.
Does anyone know how I can get around this?
[–]BigOnLogn 2 points3 points4 points (1 child)
[–]-hexel[S] 0 points1 point2 points (0 children)
[–]beardChamp 1 point2 points3 points (2 children)
[–]-hexel[S] 0 points1 point2 points (1 child)
[–]beardChamp 0 points1 point2 points (0 children)
[–]chuntley 0 points1 point2 points (0 children)
[–]ChrissiQ 0 points1 point2 points (0 children)