Try doing console.log($(this).css(backgroundColor)) in the second function
to see what those background colors are showing up as.
Yansky wrote:
I'm having a bit of trouble figuring out how to do this. What I'd like to
do is find the first parent element that has a background color that is
Daemach2 wrote:
Try doing console.log($(this).css(backgroundColor)) in the second function
to see what those background colors are showing up as.
Watch out for Safari, it sometimes returns 'rgba(0,0,0,0)' instead of
'transparent' ...
Luke
--
zinc Roe Design
www.zincroe.com
(647) 477-6016
Ah excellent - using console.log($(this).css(backgroundColor)) in the
second function shows the parent elements background colours as an array:
transparent
transparent
rgb(51, 51, 51)
transparent
transparent
so that means I'm on the right track, I've just stuffed up the if statement.
I'll keep
Yansky wrote:
I'm having a bit of trouble figuring out how to do this. What I'd like to do
is find the first parent element that has a background color that is not
transparent.
This is what I've tried so far, but with no success:
$('.elemToFade:first').parents([EMAIL PROTECTED] !=
Thanks a bunch, that's very handy code. :)
Luke Lutman wrote:
Yansky wrote:
I'm having a bit of trouble figuring out how to do this. What I'd like to
do
is find the first parent element that has a background color that is not
transparent.
This is what I've tried so far, but with no