SET HEADER AND FOOTER WITH IN MASTER PAGE

ezra heywood

Total Post:145

Points:1019
Posted by  ezra heywood
 953  View(s)
Ratings:
Rate this:

Hi Everyone!

I want to create header and footer for my master page. problem is that, When I have set div with as 100%, When we resize window then header contain

disturbed. When I have set div with in px then it's behave differ for every browsers. Pleas tell me how to manage it.

my line of code as below
<body>
<div style="header"></div>
<div style="contain"></div>
<div style="footer"></div>
</body>

Thanks in advance!

  1. AVADHESH PATEL

    Post:604

    Points:4228
    Re: set header and footer with in master page

    Hi Ezra!

    Put your div into another div and set that backgorund color same as you fixed main div.
    e.g.

    <style type="text/css">
            .maindiv
            {
                width: 100%;
                background-color: #e5e5e5;
                margin: -8px -8px 0px -8px;
            }
            .innerdiv
            {
                width: 1200px;
                height: 100px;
                background-color: #e5e5e5;
                margin: 0px auto 0px auto;
            }
        </style>

    <div class="maindiv">
            <div class="innerdiv">
            </div>
    </div>

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!