Quantcast

What works and what is paused ยท Email is limited to account activation and password resets.

Jump to content


Photo

Simple (I think?) CSS problem on petpage


  • Please log in to reply
3 replies to this topic

#1 Guppie

Guppie
  • 1285 posts


Users Awards

Posted 21 March 2016 - 06:00 AM

I have an image I want positioned at the bottom of the page, but for some reason, neo has decided that's not something I should be able to do. Is there an obvious work around I'm missing? Did I do a stupid from the start? Am I SOL?

 

Visual of what I'm after (except I lied, the top and bottom images should be in front of the repeating background image, which they currently are):

Spoiler

 

Things I've tried:

Spoiler

 

Spoiler

 

I tried a few other things (like using bot instead of bottom) that were obviously wrong, but these are my best tries.



Advertisement

    #2 Jelly

    Jelly
    • 68 posts


    Users Awards

    Posted 21 March 2016 - 02:31 PM

    Lazy idea:

     

    Position the top part with an extra element.

     

    Set your repeating background on html, not body.

     

    Set your bottom thing on body:

     

    body {

        background: url(www) bottom center;

    }

     

    That will layer on top of the html layer but behind anything else :)



    #3 Guppie

    Guppie
    • 1285 posts


    Users Awards

    Posted 21 March 2016 - 05:35 PM

    @jellyworlddoesntexist That worked! Kind of... So the I did use the body bg to put my image at the bottom, and I left the top as it was, because it was working, but now I can't get the background image to repeat correctly?

     

    It's repeating horizontally just fine, but it refuses to repeat vertically, even when I use background-repeat: repeat; which shouldn't even be necessary. What gives?

     

    #tile {
        background: url("http://i.imgur.com/letters.jpg");
        width: 100%;
        height: 1024px;
        top: 1024px;
        left: 0px;
        overflow: hidden;
    }

     

    -----

     

    <div id="tile" style="position: absolute; z-index: -1;">
    </div>



    #4 Jelly

    Jelly
    • 68 posts


    Users Awards

    Posted 24 March 2016 - 06:19 AM

    Your container in that case is only 1024px tall; not the whole page. That's why you should put the repeat-y part on something that is full-height, like <html>

     

    html {

        background: url(www);

    }


    Made a CodePen for you here: http://codepen.io/anon/pen/WwjYaw




    1 user(s) are reading this topic

    0 members, 1 guests, 0 anonymous users