I am trying to write a firefox plugin which could allow people to annotate their bookmarked web pages and store the annotations locally.
I am doing this by inserting appropriate div elements inside the body of the page and attaching appropriate handlers for allowing drag/drop kind of interactions on these elements.
While I can easily add the elements on a html page, I am not able to do so in those pages that are non-html but supported by the browser - example an image, or a plain txt file.
I guess the basic problem is that for these documents there is no body element in the dom and hence I cannot append my divs correctly.
Is there anything I can do to add the divs correctly to these non html docs on the browsers so that it renders correctly?
Thanks. Kapil