|
Posted by richard on 09/26/06 15:54
"Michael Winter" <m.winter@blueyonder.co.uk> wrote in message
news:Yw8Sg.25163$r61.5892@text.news.blueyonder.co.uk...
> JWL wrote:
>
> [snip]
>
>> #wrap2 {
>> width: 800px;
>> background-color: #FFF;
>> background: url(images/line.gif) repeat-y;
>> }
>>
>> Suddenly, wrap2 becomes transparent ...
>
> The shorthand property can also be used to specify the colour, but as you
> haven't included it, the initial value of transparent is used instead.
> That is:
>
> background: url(images/line.gif) repeat-y;
>
> is equivalent to:
>
> background: transparent url(images/line.gif) repeat-y scroll 0% 0%;
>
> As this declaration follows the explicit background-color property
> declaration, it overrides the value set there.
>
> This sort of thing applies to all shorthand properties. Either swap the
> declaration order, or include the colour in the shorthand declaration.
>
> [snip]
>
> Mike
Interesting. I've never had the problem with transparency. This also is the
first time I've read where transparent is an attribute of background. Or at
least is mandated as having that effect when not used.
Any attribute that is not used, has no effect. That's the way I understand
it.
Navigation:
[Reply to this message]
|