Forums

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

Home Forums CSS absolute positioning

  • This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #35499
    dynamyc
    Member

    I have this div :


    exactly after the body tag, and this css for the div :

    #tt {
    position:absolute;
    top: 0;
    left:50%;
    display:none;
    }

    and it’s not displayed as I expected, I mean outside of the thumbnails container.
    Why is not working?
    Here is the link.

    #92009
    TheDoc
    Member

    Maybe I don’t understand… it has a display of none, so nothing is going to show.

    #92010
    artjunkie
    Participant

    Where exactly do you want to position it?

    .jThumbnailScroller .jTscroller a has a position:relative; so each absolutely positioned title is kept within the anchor/image.

    .jThumbnailScroller .jTscroller a {
    background: none repeat scroll 0 0 #FFFFFF;
    display: block;
    float: left;
    margin: 0 10px 0 0;
    position: relative;
    }

    #92202
    dynamyc
    Member

    I want to position that fade in tittle which appears when you mouse over an image.
    I want to position it on the top center of the screen above the images.

    #92206
    jstam
    Member

    To do that the way you want you’d have to declare a width on #tt and assign it a negative left margin of half of that width. For example:


    #tt {
    border: 1px solid #000000;
    color: black;
    display: none;
    font-size: 48px;
    left: 50%;
    margin-left: -50px;
    margin-top: -30px;
    position: absolute;
    top: 0;
    width: 100px;
    }

    I added a black border to see the entire element.

    More info here: http://www.wpdfd.com/editorial/thebox/deadcentre4.html

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