By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,956 Members | 1,457 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,956 IT Pros & Developers. It's quick & easy.

Opacity?

P: n/a
Can someone point me to a good explanation of how to use opacity?
From CSS 3 http://www.w3.org/TR/2003/CR-css3-co...30514/#opacity
which I read to mean just set a decimal value between 0 and 1

I tried using opacity: 0.50; and it appeared to work as expected in
Safari and Firefox, but not in Opera. Does it actually work in any
version of IE? Does it degrade harmlessly like in Opera?

I also noticed the use of filter: alpha(opacity=50); apparently for
Internet Explorer only, and added that in an attempt to provide
something for IE to use also.

However the CSS validator says property opacity doesn't exist about the
first version, and says parse error opacity=50 about the second. I
guess that is a reasonable error message about the second if it is an IE
only variation. But I don't understand what CSS syntax I should use
instead of opacity: 0.50; if I have that wrong.

I tried both of these in http://www.sheltersrus.com.au/horse.html with
http://www.ericlindsay.com/sheltersrus.css controlling the opacity of
the text of the pseudo logo that should be in the top left hand corner
of the page (I am just using that photo for test purposes). As I said,
works in Firefox and Safari. If the "logo" falls down the page in IE
that would be nice to know also (I have dark suspicions of things
breaking).

--
http://www.ericlindsay.com
Nov 30 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Eric Lindsay wrote :
Can someone point me to a good explanation of how to use opacity?
From CSS 3 http://www.w3.org/TR/2003/CR-css3-co...30514/#opacity
which I read to mean just set a decimal value between 0 and 1

I tried using opacity: 0.50; and it appeared to work as expected in
Safari and Firefox, but not in Opera.
The latest releases (stable and dev.) of Opera (Opera 8.51 and Opera 9
beta 1) do not support opacity but I'm sure Opera dev. would love to
support CSS3 opacity.

Does it actually work in any version of IE?
Under a proprietary and non-standard feature, yes.
filter: alpha(opacity=xx)
where xx is an integer between 0 and 99.

Does it degrade harmlessly like in Opera?


Yes.

Gérard
--
remove blah to email me
Nov 30 '05 #2

P: n/a
Eric Lindsay wrote:
However the CSS validator says property opacity doesn't exist about the
first version, and says parse error opacity=50 about the second. I
guess that is a reasonable error message about the second if it is an IE
only variation. But I don't understand what CSS syntax I should use
instead of opacity: 0.50; if I have that wrong.


If you choose CSS3 profile in the validator, you only get one error
(about the filter stuff).
--
Johannes Koch
In te domine speravi; non confundar in aeternum.
(Te Deum, 4th cent.)
Nov 30 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.