[jQuery] Targeting iframes, adding id, and getting content
Here is my problem.
There are 2 iframes on my page, that I need to assign an ID to, and
then I need to get the innerHTML from each. For some reason, I can't
get jquery to add an id to the iframe at all. I tested it using div,
and that worked fine. Can you not set an id for an iframe?
$(document).ready(function(){
$("iframe").attr({
name: "frame1"
});
});
That is not seeming to work. Any ideas?
Then I was trying to get the inner html of the iframe, but I am
stumped on that too:
var summarytext = $("iframe:first").html();