Closed
Bug 340749
Opened 18 years ago
Closed 8 years ago
Need a way to do an openURI that can't be retargeted
Categories
(Core Graveyard :: Embedding: APIs, enhancement)
Core Graveyard
Embedding: APIs
Tracking
(Not tracked)
RESOLVED
INCOMPLETE
People
(Reporter: myk, Unassigned)
References
Details
Attachments
(1 file)
4.83 KB,
application/octet-stream
|
Details |
Currently, in order to invisibly parse an HTML page into a DOM document object, you have to: 1. download the content of the page (via f.e. XMLHttpRequest); 2. stick the content of the page into a data: URL; 3. create a hidden iframe (perhaps with JavaScript and other features disabled); 4. create a channel from the data: URL with the LOAD_BACKGROUND flag set; 5. call nsIURILoader::OpenURI, passing it the channel and the iframe's docShell. Following this procedure prevents accidental display of the "download" dialog box (if your HTML page turns out to have a content type you weren't expecting), may have negligible impact on UI responsiveness (still in the process of testing this), and may prevent the cursor from changing into the busy cursor (still testing this, too). But it's a painful way to obtain these benefits. There should be an better way to do this.
Comment 1•18 years ago
|
||
So how is this different from bug 102699? Or is this a bug about avoiding the "download" dialog? We should definitely have an API on URILoader to allow that....
Reporter | ||
Comment 2•18 years ago
|
||
(In reply to comment #1) > So how is this different from bug 102699? Hmm, you're right, this bug, as currently stated, is the same as bug 102699. > Or is this a bug about avoiding the "download" dialog? We should definitely > have an API on URILoader to allow that.... We can morph it to be that bug.
Updated•18 years ago
|
Assignee: mrbkap → nobody
Component: HTML: Parser → Embedding: APIs
QA Contact: parser → apis
Summary: a better way to invisibly parse HTML → Need a way to do an openURI that can't be retargeted
Comment 3•18 years ago
|
||
-> me, unless someone else wants it :)
Assignee: nobody → cbiesinger
Target Milestone: --- → mozilla1.9alpha
Comment 4•18 years ago
|
||
XMLHttpRequest's .responseDocument should just support text/html, IMHO.
Comment 5•18 years ago
|
||
this bug is now unrelated to XMLHttpRequest, implementing this new summary is useful independent of whether XMLHttpRequest supports text/html.
Comment 6•17 years ago
|
||
bug 384941 adds an openURIWithFlags function to which you can pass nsIURILoader::DONT_RETARGET
Depends on: 384941
Target Milestone: mozilla1.9alpha1 → ---
Comment 7•17 years ago
|
||
That bug doesn't have that change anymore, but I've separated it out into a separate patch.
Updated•12 years ago
|
Assignee: cbiesinger → nobody
Comment 8•8 years ago
|
||
Marking a bunch of bugs in the "Embedding: APIs" component INCOMPLETE in preparation to archive that component. If I have done this incorrectly, please reopen the bugs and move them to a more correct component as we don't have "embedding" APIs any more.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → INCOMPLETE
Updated•5 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•