Forums

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

Home Forums CSS top:0px rendering wrong

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #146853
    shart291
    Participant

    I am trying to manually position elements on a client’s site. all of the segments that are positioned are using Absolute Positioning as I was experiencing some bad side effects that were actually worse that what I am getting now.

    each element is positioned off of the top and left.

    In Chrome the element I am using appears right below the nav, in the correct spot using the following code. position:absolute;
    top:0px;

    However it seems to be working like relative positioning as the top value is not based off of the top of the viewport, rather it seems the reference is the original location for this element.

    It’s weird because in firefox, it is being based off of the top viewport.

    I don’t see any rogue css anywhere. Why would an absolutely positioned element behave like a relatively positioned one on only the top value?

    It is weird.

    If anyone needs additional info the dev site is Here and the element is the main div for the Category A column on the left hand side.

    aside from the slider, all other elements appear to be affected this way as well. top positioning values behave as if they are using relative positioning, even though they are not.

    here is a code pen link, it contains all the main styles used and the complete rendered code for the page.

    http://codepen.io/anon/pen/tsduH

    The styles are specific to the front page of this site.

    #146883
    Paulie_D
    Member

    I should add that absolutely positioning everything is a very bad idea

    Very much agree with this….the last option one should choose…even after TABLES!

    QFT.

    The Codepen doesn’t render in ‘pen’ mode but FullScreen does…mostly. :http://codepen.io/anon/full/tsduH

    Layout doesn’t look that problematical to do in other ways.

    #146900
    shart291
    Participant

    The problem is that the headers disappear when I use relative positioning to get everything where I need it to be.

    How else would you approach this because relative positioning was way worse in chrome than absolute.

    #146901
    Paulie_D
    Member

    Standard floats or inline:block would seem to be a much better option rather than positioning (whether absolute or relative).

    http://learnlayout.com/

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘CSS’ is closed to new topics and replies.