Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
TWO backgrounds for the body?
Old 06-22-2009, 12:27 PM TWO backgrounds for the body?
Novice Talker

Posts: 5
Trades: 0
Is it possible? I have a background with a textured canvas surface and paint splotches all over it. I only made the image have a height of 2000px. That seemed enough to me at the time. But I want to allow the page to scroll down to an indeterminate length. I don't want another scrollbar, btw.

So is it possible to have another image after the first background? I would have that image repeat, but I can't have the first one repeat.

Code:
BODY, html {
    background-color: #D5E8F1;
    background-image: url(wallpaper.gif);
    background-repeat: no-repeat;
    margin: 0px;
 }
 
 #bigwrapper {
  width: 880px;
  margin-left: 100px;
  padding-top: 10px;
  max-height: 1980px;
  overflow: hidden;
 }
 
 #sideBanner {
    width: 80px;
    height: 600px;
    background-image: url(bannerSide.gif);
    float:right;
    background-repeat: no-repeat;
    margin-top: -27px;
    margin-left: 15px;
 }
 
 /* holds everything, except the bottom container, together */
 #wrapper {
  width: 778px;
  margin: auto;
  /*background-color: #F0EEA5;*/
  border-right: 1px solid #DAB939;
  border-left: 1px solid #DAB939;
  margin-bottom: 20px;
  float:left;
  background-image: url(bg_wrapper.gif);
 }

Last edited by Cyborg Ninja; 06-22-2009 at 12:31 PM..
Cyborg Ninja is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 06-22-2009, 12:53 PM Re: TWO backgrounds for the body?
EricReese's Avatar
Super Talker

Posts: 137
Name: Eric Reese
Location: Maryland, USA
Trades: 0
You can't have two background images for the same element in CSS 2.1 but CSS3 allows this. And seeing as most browsers dont support this...you could maybe use two divs and set a background image for each div.
__________________
I am 17 years old.Looking for Web Design Job(s). If interested use my
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE

Funny Line- "I'll Twitter your Yahoo! until I Google all over your FaceBook :D
EricReese is offline
Reply With Quote
View Public Profile Visit EricReese's homepage!
 
Old 06-22-2009, 12:58 PM Re: TWO backgrounds for the body?
Novice Talker

Posts: 5
Trades: 0
What do you mean by "most browsers?" I thought nearly all support CSS3, except IE's twisting of standards, but I would test it in IE myself.
Cyborg Ninja is offline
Reply With Quote
View Public Profile
 
Old 06-22-2009, 01:24 PM Re: TWO backgrounds for the body?
EricReese's Avatar
Super Talker

Posts: 137
Name: Eric Reese
Location: Maryland, USA
Trades: 0
Most browsers support some properties of CSS3 but I think you misunderstand that. CSS3 is comprised of many many properties. No browser today supports them all. which is why you shouldn't be using CSS3 in your website because only certain browsers will display the effects of that property. That is one reason why a lot of browsers started using vendor extensions for their browsers.

If I remember correctly, only Safari 4, and I think FF 3.5 support multiple background images on an element.

HTH, Cheers
__________________
I am 17 years old.Looking for Web Design Job(s). If interested use my
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE

Funny Line- "I'll Twitter your Yahoo! until I Google all over your FaceBook :D
EricReese is offline
Reply With Quote
View Public Profile Visit EricReese's homepage!
 
Old 06-22-2009, 02:37 PM Re: TWO backgrounds for the body?
Novice Talker

Posts: 5
Trades: 0
Ok, I see. I feel like it would be considered bad coding (can I apply "programming" to CSS?) if I made two divs for the background. If I try overflow, I get two scrollbars. I don't want to limit the amount of content posted on the website, and I don't want to create the background image all over again.
Cyborg Ninja is offline
Reply With Quote
View Public Profile
 
Old 06-22-2009, 02:42 PM Re: TWO backgrounds for the body?
EricReese's Avatar
Super Talker

Posts: 137
Name: Eric Reese
Location: Maryland, USA
Trades: 0
We would need a link to the website in question for us to help you CSS isn't programming because of obvious reasons. CSS could be called coding, or even a stretch, scripting. Why not just keep overflow:visible, instead of auto, or is your background image a fixed one?

Cheers
__________________
I am 17 years old.Looking for Web Design Job(s). If interested use my
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE

Funny Line- "I'll Twitter your Yahoo! until I Google all over your FaceBook :D
EricReese is offline
Reply With Quote
View Public Profile Visit EricReese's homepage!
 
Old 06-22-2009, 03:55 PM Re: TWO backgrounds for the body?
Novice Talker

Posts: 5
Trades: 0
Like I said, I cannot have overflow because the background is an image that would look odd if it repeated.
Cyborg Ninja is offline
Reply With Quote
View Public Profile
 
Old 06-22-2009, 07:01 PM Re: TWO backgrounds for the body?
EricReese's Avatar
Super Talker

Posts: 137
Name: Eric Reese
Location: Maryland, USA
Trades: 0
Then you would need to have a fixed max amount of content, and anything more would have to have an overflow: auto; on the content div with a set height.

Cheers
__________________
I am 17 years old.Looking for Web Design Job(s). If interested use my
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE

Funny Line- "I'll Twitter your Yahoo! until I Google all over your FaceBook :D
EricReese is offline
Reply With Quote
View Public Profile Visit EricReese's homepage!
 
Old 06-22-2009, 11:07 PM Re: TWO backgrounds for the body?
Novice Talker

Posts: 5
Trades: 0
I thought we already answered those questions in the first two posts. I'd like other suggestions.
Cyborg Ninja is offline
Reply With Quote
View Public Profile
 
Old 06-23-2009, 10:29 AM Re: TWO backgrounds for the body?
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
There aren't many. We at least need to see your code and the backgrounds. Trying to envision your scenario w/o the actual images isn't helpful.

There are other ways to clear floats without the overflow option, it's not as clean, but it does work.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 06-23-2009, 10:46 AM Re: TWO backgrounds for the body?
EricReese's Avatar
Super Talker

Posts: 137
Name: Eric Reese
Location: Maryland, USA
Trades: 0
One such method is the clearfix method:

http://www.webtoolkit.info/css-clearfix.html
http://www.positioniseverything.net/easyclearing.html

Cheers
__________________
I am 17 years old.Looking for Web Design Job(s). If interested use my
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE

Funny Line- "I'll Twitter your Yahoo! until I Google all over your FaceBook :D
EricReese is offline
Reply With Quote
View Public Profile Visit EricReese's homepage!
 
Reply     « Reply to TWO backgrounds for the body?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.56610 seconds with 12 queries