Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Relatively Positioned Submenu and Background Banner Doesnt Fill Width of Screen

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #281584
    lastpeony
    Participant

    I am trying to position submenu div and a banner made from a background.

    The problem is they are not filling width of screen.There are small white spaces on left and right sides.
    Also in my real app,submenu div is appearing after a button click,so it must push below element down.I mean i can achieve 100% width if i make submenu absolute position,but then below banner div is not pushed down.

    Here is the codepen with minimized problem:

    https://codepen.io/anon/pen/roEQqo

    Gif for better explanation:
    https://i.imgur.com/TvPDHyE.gifv

    #281588
    Shikkediel
    Participant

    I think you’re referring to the default margin on the body element.

    body {
      margin: 0;
    }
    
Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘CSS’ is closed to new topics and replies.