Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6848379
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T00:51:39+00:00 2026-05-27T00:51:39+00:00

I have a nested div element: <div id=footer> <div id=footer_text> <p>My foooo text</p> </div>

  • 0

I have a nested div element:

        <div id="footer">
            <div id="footer_text">
                <p>My foooo text</p>
            </div>
        </div>

and its CSS code:

#footer
{
    position: absolute;
    bottom: 0px;
    margin-bottom: 5px;
    margin-right:50px;
    margin-left:50px;
    width:90%;
    height:16px;
    color:white;
    font-size:12px;
    background:#000000;
    border-style:solid;
    border-width:1px;
    border-color:#F0FFFF;
    text-align: center;

}

Seems to work fine in firefox 7. The problem is that it only works when I don’t have the

<p>My foooo text</p>

when I add it, is appears the text outside the div border, and it also brings up an annoying vertical scroll bar.

I tried some solution here, but I can’t seem to make it work..

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T00:51:40+00:00Added an answer on May 27, 2026 at 12:51 am

    This is because p element has default margin

    I think it is good solution to reset margins and paddings for everything at the start:

    * {
    padding: 0;
    margin: 0;
    }
    

    Anyway you can just add

    p {
    margin: 0;
    }
    

    Moreover you don’t need to set height of footer to get it as you want. It is better to use paddings. You get everything vertical centered atuomatically when you set the same top and bottom padding
    .

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an element (for example, a body) nested somewhere inside a div.. Something
I have webpage with a video element nested in a div class=video-container along with
I have a xml document having nested level <div> element with attribute. I want
I'm using colorbox on a div. I have nested div's. When i click the
If any of the nested div s below have a length longer then an
I have those 2 divs nested into the yellow div, and as you can
I have a popup div with a scrolling nested div. I want to be
Little help need with jquery sortable. I have a nested list like so: <div
I have two divs, one nested inside of the other. The parent element has
I have two <div> , one nested into the other defined like this: <div

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.