[jQuery] Re: need help with opacity

2008-09-04 Thread Cybernoxa

In addition to my previous words:
every element which is within other element which has opacity lower
then 1 will inherit its parent's opacity.

For example if you place paragraph in div with opacity: 0.7, the
paragraph will have the same (even if you give him opacity: 1)

 http://www.twinhelix.com/css/iepngfix/
The solutions from Turbodurso are OK, but I do not use JS for IE, I'm
quite sure we can ignore IE 5, just focus on IE6 and higher


So lets say this is the code:

div id=transpBg
pSome text/p
/div

normal css (even for IE 6)
#transpBg { background: transparent url(transp.png); }

css for ie 6 (in special stylesheet or star hack)
#transpBg {
background: none !important; /* necessary */
filter:
progid:DXImageTransform.Microsoft.AlphaImageLoader(src=transp.png,
sizingMethod=crop);
/* check dependences between sizing method and how it shows pics */
z-index: 1;
/* has Layout fix - there are some ways to do it this is one of them
*/
}


But I'm sure you know it now, just wanted to help in case if you
don't :)
Tom


[jQuery] Re: need help with opacity

2008-09-03 Thread bobh

Ack, that's a bit of a blow :) Time to rethink my design concept...
Thanks Tom.

On 2 sep, 17:11, Cybernoxa [EMAIL PROTECTED] wrote:
  div
          img src=photo.jpg /
  /div

  and I'm doing a simple css thing to control theopacity:

  $(div).css({opacity: 0.11});

 Hi Bob - sorry for my english ;)
 As img is a child of div it takes the opacity from it's parent, so
 there's nothing you can do.
 When you set opacity: 1 for img it just mean that it has the same
 opacity as its parent (11%).

 The only thing you can do IMHO is to place the img outside the div and
 position it into right place.

 I hope I helped ;)
 Tom


[jQuery] Re: need help with opacity

2008-09-03 Thread turbodurso

Hey bob, you don't necessarily have to rethink your design, just use
transparent png files (tiled for background)

They can now render on all browsers (including IE 5 +) with this
little fix :

http://www.twinhelix.com/css/iepngfix/

Also, this dwld is quite handy for transparent backgrounds:

http://css-tricks.com/examples/TranspFills.zip

india



[jQuery] Re: need help with opacity

2008-09-03 Thread bobh

Yes, I realised this a few hours ago. I was focussing too much on the
solid bg color.

On 3 sep, 17:48, turbodurso [EMAIL PROTECTED] wrote:
 Hey bob, you don't necessarily have to rethink your design, just use
 transparent png files (tiled for background)

 They can now render on all browsers (including IE 5 +) with this
 little fix :

 http://www.twinhelix.com/css/iepngfix/

 Also, this dwld is quite handy for transparent backgrounds:

 http://css-tricks.com/examples/TranspFills.zip

 india


[jQuery] Re: need help with opacity

2008-09-02 Thread Cybernoxa



 div
         img src=photo.jpg /
 /div

 and I'm doing a simple css thing to control theopacity:

 $(div).css({opacity: 0.11});

Hi Bob - sorry for my english ;)
As img is a child of div it takes the opacity from it's parent, so
there's nothing you can do.
When you set opacity: 1 for img it just mean that it has the same
opacity as its parent (11%).

The only thing you can do IMHO is to place the img outside the div and
position it into right place.

I hope I helped ;)
Tom