JOIN DEVPPL

It looks like you are new here. If you want to get involved, click on Join below!



How to include duplicate markup in every web page


K

keyboard_arrow_up
0
keyboard_arrow_down


First Post Mark as Spam kenjones
Posts: 3 - Registered: 2013-05-22 09:41:15

If all my html web pages have the same navigation and footer markup, what is the best way of avoid hard-coding this in every page, so if it needs changing it's only changed in one place so as not to have to edit every html file?

Thanks




K

keyboard_arrow_up
1
keyboard_arrow_down


Reply #2 Mark as Spam kenjones
Posts: 3 - Registered: 2013-05-22 09:41:15

Hi, thanks for getting back.

I've decided to use JavaScript to load either a HTML template or construct the HTML dynamically and assign the HTML to a placeholder, ie a <div

This way I can write one JS module and include in my HTML page, and so avoiding duplication.

Cheers!






JOIN DEVPPL

It looks like you are new here. If you want to get involved, click on Join below!




MENU
Advertising