As was foretold, we've added advertisements to the forums! If you have questions, or if you encounter any bugs, please visit this thread: https://forums.penny-arcade.com/discussion/240191/forum-advertisement-faq-and-reports-thread/
Options

CSS background scrolling shenanigans

DelzhandDelzhand Hard to miss.Registered User regular
edited February 2009 in Help / Advice Forum
Here's a head scratcher. I have a background that I do not want to scroll with the page. It is currently set to the background image of #page, which is enclosed in #body. #Page is fixed width, centered in the body. The default setting is background-attachment: scroll. But if I use background-attachment: fixed, it stays where it's supposed to be, but it aligns the background image to the body (or maybe the window) instead of the page element.

I can't used background positioning, because #page is centered.

Any ideas?

Edit: W3.org confirms that using fixed sets a background to the viewport... informative but unhelpful for this design.

Delzhand on

Posts

  • Options
    JasconiusJasconius sword criminal mad onlineRegistered User regular
    edited February 2009
    I think that's pretty much how it works, you can't get around it.

    If I read you right you want this image to just stay put when you scroll around... then I'm thinking you need to set the actual element to be fixed

    or something



    or don't use tacky design elements ;)

    Jasconius on
  • Options
    DelzhandDelzhand Hard to miss. Registered User regular
    edited February 2009
    Yeah, I don't know what the fuck I'm doing with this site. I've made it impossible to read, which is sort of okay for now, since I neither have nor expect readers.

    I'm a game designer, not a graphic designer, and I think it shows. Maybe I should just cop out and use 2008's trends. I'll just make everything glossy and put mirror reflections under every bit of content.

    Delzhand on
  • Options
    admanbadmanb unionize your workplace Seattle, WARegistered User regular
    edited February 2009
    Delzhand wrote: »
    Yeah, I don't know what the fuck I'm doing with this site. I've made it impossible to read, which is sort of okay for now, since I neither have nor expect readers.

    I'm a game designer, not a graphic designer, and I think it shows. Maybe I should just cop out and use 2008's trends. I'll just make everything glossy and put mirror reflections under every bit of content.

    Or you could make a simple, text-based page with a simple color layout (example: grey background, white foreground, with the foreground being anywhere you have text, a light blue/green/red for menu type stuff). The basics of design are not that hard. Just make something simple and work from there.

    admanb on
  • Options
    JasconiusJasconius sword criminal mad onlineRegistered User regular
    edited February 2009
    See if position:fixed on the thing you have the background on will get you closer to what you want.

    Jasconius on
Sign In or Register to comment.