Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to create a master page using HTML? [closed]

I have a website which I want to have a consistent style (a header and a side menu) in every page.

I want to create something similar to a master page for it. I don't want to use frames.

How could I achieve this using HTML, CSS, JavaScript and jQuery?

like image 385
Aisha Avatar asked Aug 27 '13 11:08

Aisha


People also ask

How do I create a master page for my website?

To create a master page, right-click on the project name in the Solution Explorer and choose Add New Item. Then select the Master Page type from the list of templates and name it Site. master .

How do I create a master page after creating a Web form?

Add the master page into our project. Right click Project->Add->New item (shown in the picture), After clicking on new item, Window will open, select Web Form->Web Forms Master Page (shown in the picture), After clicking the add button, master page 'site1.

What is master page how it is created?

Master page allows you to create a consistent look and behavior for all the pages in your web applications. Master Page Design is common for all the pages. Master page actually consists of two pieces, the master page itself and one or more content pages. A master page is an ASP.NET file with the extension .


1 Answers

you can use jQuery Load function to include header or menu html page, for example, to include a common header html file,

    <div id="new-header">
        <script>
            $("#new-header").load("header.html");
        </script>
    </div>
like image 59
Able Alias Avatar answered Sep 28 '22 06:09

Able Alias