I'm ultimately trying to find all image tags on a page and print out the ones without alt tags.
Right now I have this:
var str = '<img id="img1" /><img id="img2" /><img id="img3" /><img id="img4" alt="ASDF" title="" /><img id="img5" alt="" /><img id="img6" title="" />';
var imagesWithoutAlt = $( str ).filter( 'img:not([alt])' );
var newString = new String( $( imagesWithoutAlt ).clone().html());
$(document.body).append($('<textarea rows="6" cols="40"/>').text( newString );
But this is failing to output anything. Help?