Forums
View unanswered posts | View active topics It is currently Sat Dec 20, 2014 8:24 am



Reply to topic  [ 3 posts ] 
 Multiple Backgrounds 
Author Message

Joined: Fri Nov 19, 2010 11:00 pm
Posts: 2
Post Multiple Backgrounds
Hey guys,

I'm having problems getting multiple background images to work in IE.

Code:
#wrapper-inner {
   width: 100%;
   height: 400px;
   border: 1px solid #fff;
   -webkit-border-radius: 3px;
   -moz-border-radius: 3px;
   border-radius: 3px;
   background: #efefef;
   background-image: url(../../images/backgrounds/border.png), url(../../images/backgrounds/border.png);
   background-repeat: no-repeat;
   background-position: top left, top right;
   -pie-background: #efefef, url(../../images/backgrounds/border.png) top left, url(../../images/backgrounds/border.png) top right;
   behavior: url(PIE.htc);
}


In IE the background colour appears as well as the rounded border but the images do not.

I've searched these forums and have tried a few things like making the pie-background image paths relative to the .html file not the .css file etc without luck.

Any help would be appreciated, it's probably something simple i'm doing wrong.


Fri Nov 19, 2010 11:08 pm
Profile

Joined: Wed Jul 14, 2010 11:46 am
Posts: 1448
Post Re: Multiple Backgrounds
The CSS3 spec indicates that only the last item in the background shorthand can contain a color. Since you have it first, that is an error. I'm not sure off the top of my head how PIE handles that error but it's possible that's the cause of your problem.

Images do have to be relative to the HTML document in this case, unfortunately.


Fri Nov 19, 2010 11:30 pm
Profile

Joined: Fri Nov 19, 2010 11:00 pm
Posts: 2
Post Re: Multiple Backgrounds
Thanks for your response,

I somehow missed the thread below this and found the solution.

I needed to add position: relative and z-index along with the relative image paths like you said.


Fri Nov 19, 2010 11:36 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 3 posts ] 

Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.