Opened 9 years ago

Last modified 5 years ago

#16440 assigned defect

dojo/request/iframe.js, xmlText is undefined error in FF and IE9

Reported by: taoyan Owned by: dylan
Priority: undecided Milestone: 1.15
Component: IO Version: 1.8.1
Keywords: Cc:
Blocked By: Blocking:


I use to upload attachment, after upgrading Dojo from 160 to 181, there is a "xmlText is undefined" error in FF or IE9, but works well in IE8. I compare codes between Dojo 160 and 181 and find, the error is in dojo/request/iframe.js, handleResponse method

if(handleAs !== 'html'){

if(handleAs === 'xml'){

IE6-8 have to parse the XML manually. See

if(doc.documentElement.tagName.toLowerCase() === 'html'){

query('a', doc.documentElement).orphan();

var xmlText = doc.documentElement.innerText;

xmlText = xmlText.replace(/>\s+</g, '><');

response.text = lang.trim(xmlText);

}else{ = doc;



in FF, IE9 or Chrome, doc.documentElement.innerText is undefined. Dojo 160, dojo/io/iframe.js, send method

if(handleAs != "html"){

if(handleAs == "xml"){

FF, Saf 3+ and Opera all seem to be fine with ifd being xml. We have to

do it manually for IE6-8. Refs #6334.

if(dojo.isIE < 9
(dojo.isIE && dojo.isQuirks)){

dojo.query("a", dii._frame.contentWindow.document.documentElement).orphan();

var xmlText=(dii._frame.contentWindow.document).documentElement.innerText;

xmlText=xmlText.replace(/>\s+</g, "><");



to prevent this kind of error, but in Dojo 181 it changes to

if(doc.documentElement.tagName.toLowerCase() === 'html')

is it a bug? if not, is there a document about how to use this feature? Thanks!

Change History (3)

comment:1 Changed 9 years ago by bill

Component: GeneralIO
Owner: set to Bryan Forbes

comment:2 Changed 6 years ago by dylan

Milestone: tbd1.12
Owner: changed from Bryan Forbes to dylan
Status: newassigned

comment:3 Changed 5 years ago by dylan

Milestone: 1.131.15

Ticket planning... move current 1.13 tickets out to 1.15 to make it easier to move tickets into the 1.13 milestone.

Note: See TracTickets for help on using tickets.