Thanks for the resopnse astupidname. Appreciate that you ignored my constraint. This page resides at a client and I do not have control over it.
I have tried this approach. It fails when you add another div after the target div on the page. It should find the last div of the currently parsed ones, target div being the last. However, when I get the divs array, it has the subsequent div on the page as well.
I think this is because jsonp request is asynchronous and browser moves on to parsing the next element. Maybe you can shed more light on why this happens.