Is it possible to have a regular html page inherit its layout from another html page? If so, what is the most advisable approach for doing this? I know that aspx uses .master pages to hold the elements common to all pages in the site.
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
You could fetch resources using JS and AJAX if you absolutely cannot use a serverside language.
how can we avoid header and footer code repeating in each html pages
Jekyll works too: What is the best way to manage duplicate code in static HTML websites
回答2:
You could also use get variables and php functions to create and display the content dynamically and avoid using more that one HTML