I'm working on a Google Chrome 'context' script
From the Chrome console, or a 'normal' tag, I can do :
win1 = window.open('some url');
b1 = win1.document.body.innerHTML;
But from a chrome 'context' script, it fails with
Uncaught TypeError: Cannot read property 'document' of undefined
What is the "magic incantation" I need ?
This seems to be close to what I need, but it doesn't show where to
put code to have the popup return a dom element:
http://stackoverflow.com/questions/7063263/how-to-access-dom-and-or-window-document-object-of-a-popup-in-chrome-extension
I don't fully understand the code there (nested scopes and things), so
I'm trying to figure out where I'd put something like:
var getStuff = $('#baz').html();
Maybe some one would like to write a blog post 'disecting' that
code ? :)
Mike