Page 1 of 1

CSS background attribute for TD in FF

Posted: Fri Jun 01, 2007 7:01 am
by kendall
Hi guys,

I'm using the below css attribute

Code: Select all

.topleft{
	background: url(images/top-left-corner.gif) fixed no-repeat top left; 

}
to make round corners for my tables. However for some reason...it displays only in IE but not FireFox. Can anyone give me some insight as to what is going on.

Posted: Fri Jun 01, 2007 7:11 am
by jayshields
Could be because you've skipped the background colour and swapped the repeat and attachment attributes.

Code: Select all

.topleft{
        background: transparent url('images/top-left-corner.gif') no-repeat fixed top left;

} 

Posted: Fri Jun 01, 2007 7:11 am
by superdezign
Probably because you're using tables. That'd work fine in a regular block element.

Posted: Fri Jun 01, 2007 10:53 am
by kendall
superdezign wrote:Probably because you're using tables. That'd work fine in a regular block element.
thanks...wierd something like that would not work on of all browsers FF

Posted: Fri Jun 01, 2007 11:07 am
by superdezign
Yeah, true.
However, Firefox doesn't support some things that IE does, just like IE doesn't support some (a lot of) things that FF does.

As long as one is owned by Microsoft and one is not, their bound to be at ends.


But yea, if you get Firebug, then you can assign the individual attributes and it will collapse them into one for you.

i.e.
In CSS:

Code: Select all

background-color: rgb(0, 0, 0);
background-image: url(http://somewhere.com/someimage.jpg);
background-repeat: no-repeat;
background-attachment: fixed;
background-position: top center;
In Firebug:

Code: Select all

background: #000000 url(http://somewhere.com/someimage.jpg) no-repeat fixed center top;
I'm not sure why Firebug seems to switch the vertical and horizontal alignment, but it does every time I look at it.

Posted: Fri Jun 01, 2007 12:05 pm
by kendall
any alternatives?

im not a CSS person but i have been playing around with "positions" and "top"...

Posted: Fri Jun 01, 2007 12:24 pm
by superdezign
Alternatives to what?

If you mean the collapsed background property, the best thing to do is define each one separately.

Posted: Fri Jun 01, 2007 5:01 pm
by Ollie Saunders
Actually I don't think fixed is supported by IE.