Try:
$(document).ready(function(){
if ($('#medalist li.active').children().is('img')){
alert("true");
}else{
alert("false");
}
});
There are typos errors in your sintaxe. Double check it!
-Mensagem Original-
De: "jdenkaat" <[EMAIL PROTECTED]>
Para: "jQuery (English)"
Enviada e
this should work:
if ($("#medalist > ul > li:active img").length() > 0) {
// has image inside
}
On Oct 13, 3:52 am, jdenkaat <[EMAIL PROTECTED]> wrote:
> Hi
>
> If I have the following list and I want to find if the contents of class="active"> is an image how would I do it?
>
>
>
2 matches
Mail list logo