Closed Bug 9850 Opened 25 years ago Closed 13 years ago

{dom1}createEntityReference returning null


(Core :: DOM: Core & HTML, defect, P2)






(Reporter: dbaron, Unassigned)




(Keywords: dom1, Whiteboard: [nsbeta3-][rtm-])

document.createEntityReference is returning null in an XML document.  It should
be supported.

Observed: Running the above test case gives one error message:
"TEST(S) OMITTED: entref is null."

Expected: Test runs to end.
Target Milestone: M15
Do we need this for beta?
Priority: P3 → P2
Target Milestone: M15 → M11
HTML DOM bugs are M11/P2 for Vidur.
Target Milestone: M11 → M14
Moving to M14.
Assignee: vidur → nisheeth
Handing this one to Nisheeth pending a decision what to do with entity
references and expat.
Target Milestone: M14 → M17
Bulk moving all M14 non-beta stopper bugs to M17...
Moving bugs out by one milestone...
Target Milestone: M17 → M18
Move back into M17...
Target Milestone: M18 → M17
I meant move back into M16...
Target Milestone: M17 → M16
Johnny, regardless of whether we decide to pass up entity refernces in expat, 
document.createEntityReference() needs to be implemented so that entitities 
defined in the internal subset of an XML document can be created through the 

Should I re-assign this bug to you?
Are we (in the content sink) given a list of entities defined in the internal
subset? If we are, then supporting creation of references to text (without
markup) or character entities defined in the internal subset (or external subset
for that matter, as long as we're given a list or the defined entities) is
trivial, but supporting creation of references to entities that contain markup
is not as easy, we need to get the DOM tree (ie parse the replacement text) for
the content in the entity we're referensing, same goes for external entities,
but that's even harder since the external file might need to be parsed,
preferably synchronously, and that's not something we can easily do right now
in mozilla AFAIK.

To have a general and clean sollution for this bug I think we need to have bug
15119 (script way of loading XML...), if we had this we could simply use that
service to always parse the entity replacement text, or we could use that
service to load the external file that the entity points to.

What are the plans for bug 15119, do you have any plans for that? Once that is
fixed I'd be glad to take over this bug :)
Hi Johnny,

I'm passing this to you for now.  Bug 15119 is fixed but you also need:

a) bug 15118 fixed, and
b) a way to generate a DOM from a string

before you can implement this.  I'll try to work on a) and b) next...
Assignee: nisheeth → jst
M16 has been out for a while now, these bugs target milestones need to be 
Nominating this for nsbeta3.
Keywords: nsbeta3
OS: Linux → All
Hardware: PC → All
Target Milestone: M16 → M18
correctness of DOM1 implementation.
Keywords: correctness
Depends on: 15118
Keywords: helpwanted
Whiteboard: [nsbeta3-]
Marking nsbeta3- for now...
Mass update of qa contact
QA Contact: gerardok → janc
Nominating for rtm
Keywords: rtm
We will not be able to implement this functionality until post Netscape 6.0.
Marking rtm- and futuring.
Whiteboard: [nsbeta3-] → [nsbeta3-][rtm-]
Target Milestone: M18 → Future
Keywords: dom1
Component: DOM Level 1 → DOM Core
QA contact Update
QA Contact: janc → desale
Updating QA contact to Shivakiran Tummala.
QA Contact: desale → stummala
nominating for nsbeta1, the main purpose of this method is defeated. I think 
this missed major milestones.
Blocks: 125665
Mass-reassigning bugs to
Assignee: jst → dom_bugs
*** Bug 41286 has been marked as a duplicate of this bug. ***
*** Bug 36870 has been marked as a duplicate of this bug. ***
Blocks: 256021
Component: DOM: Core → DOM: Core & HTML
QA Contact: stummala → general
Assignee: general → nobody
Flags: wanted1.9.2?
Depends on: 611983
11 years later, document.createEntityReference is still poorly supported by other browsers. IE9 (so far) and Opera don't even implement it. Chrome tries hard, but its implementation is broken.
Target Milestone: Future → mozilla2.0
Removing helpwanted since this is being removed in bug 611983. This won't make 2.0 afaict.
Flags: wanted1.9.2?
Keywords: helpwanted
Target Milestone: mozilla2.0 → ---
Removed support altogether.
Closed: 13 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.