Closed
Bug 69840
Opened 24 years ago
Closed 21 years ago
document.createProcessingInstruction for XHTML not implemented
Categories
(Core :: DOM: Core & HTML, defect, P3)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
mozilla1.7beta
People
(Reporter: mhearn, Assigned: bzbarsky)
Details
(Keywords: dom2)
Attachments
(2 files, 2 obsolete files)
305 bytes,
application/xhtml+xml
|
Details | |
10.52 KB,
patch
|
jst
:
review+
jst
:
superreview+
|
Details | Diff | Splinter Review |
Hi, basically I need this command for an app I am writing with Mozilla. Please
can it be implemented, I doubt it's hard :)
thanks -mike
Comment 1•24 years ago
|
||
Creating processing instructions does work in XML document, are you trying to
create processing instructions in HTML? (that should not work so I wouldn't
count on that being implemented any time soon). Or did you try this in XUL?
Please give more details.
Comment 2•24 years ago
|
||
need a test case...
Updated•24 years ago
|
Component: DOM Level 2 → DOM HTML
Reporter | ||
Comment 3•24 years ago
|
||
I was trying it in XUL and got the error "Method not implemented" so I assumed
it had been futured or something. Am I wrong?
Comment 4•24 years ago
|
||
Comment 5•24 years ago
|
||
I just attached a fix for this, good ol' cut n' paste style fix for now :-).
r/sr= anyone?
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
OS: other → All
Priority: -- → P3
Hardware: PC → All
Whiteboard: [HAVE FIX]
Target Milestone: --- → mozilla0.9
Comment 6•24 years ago
|
||
r=jag
Comment 8•24 years ago
|
||
Fix cheked in, thanks for the reviews.
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Reporter | ||
Comment 9•24 years ago
|
||
Wow, thanks guys, that was very fast :)
Comment 10•24 years ago
|
||
How on earth did I end up QA on this. -> desale@netscape.com
Component: DOM HTML → DOM Core
QA Contact: ian → desale
Comment 12•24 years ago
|
||
Comment 13•24 years ago
|
||
looks like it is not yet implemented...reopening bug...
This is what javascript console reads
Error: uncaught exception: [Exception... "Component returned failure code:
0x80530009 [nsIDOMHTMLDocument.createProcessingInstruction]"
nsresult: "0x80530009 (<unknown>)" location: "JS frame ::
file:///c|/kiran/test/69840.html :: <TOP_LEVEL> :: line 6" data: no]
testcase shamelessly stolen from
http://www.zvon.org/xxl/DOM1reference/Output/examples/Document_createProcessingI
nstruction.html
testcase:
<html>
<body>
<script>
var pi = document.createProcessingInstruction('php', 'echo("another example")');
var output1 = pi.target;
var output2 = pi.data;
alert (output1);
alert (output2);
</script>
</body>
</html>
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Comment 14•24 years ago
|
||
You tried this on a html document.
Comments from jst on 2001-02-22:
"are you trying to create processing instructions in HTML? (that should not work
so I wouldn't count on that being implemented any time soon)"
I guess it depends whether there is another bug for createProcessingInstruction
for HTML.
Comment 15•24 years ago
|
||
As the current DOM HTML spec is written a HTML DOM should *not* implement this
method, so mozilla does the right thing.
However, for XHTML documents this should work, but we're not quite there yet.
Futuring.
Status: REOPENED → ASSIGNED
Target Milestone: mozilla0.9 → Future
Comment 16•24 years ago
|
||
Adding "for XHTML" to the summary so that we don't confuse with XUL or HTML.
Removing [HAVE FIX] from whiteboard. Sorry for the spam.
Summary: document.createProcessingInstruction not implemented → document.createProcessingInstruction for XHTML not implemented
Whiteboard: [HAVE FIX]
Updated•23 years ago
|
Priority: P3 → P5
Comment 17•22 years ago
|
||
Filed bug 166467 for a similar bustage in XUL (which has been touched on
previously here, but apparently not investigated yet).
Comment 18•22 years ago
|
||
Mass-reassigning bugs to dom_bugs@netscape.com
Assignee: jst → dom_bugs
Status: ASSIGNED → NEW
![]() |
Assignee | |
Comment 19•21 years ago
|
||
Attachment #40459 -
Attachment is obsolete: true
![]() |
Assignee | |
Comment 20•21 years ago
|
||
Just push the function up to nsDocument and make sure HTML doesn't call them.
Attachment #26137 -
Attachment is obsolete: true
![]() |
Assignee | |
Updated•21 years ago
|
Attachment #142506 -
Flags: superreview?(jst)
Attachment #142506 -
Flags: review?(jst)
Comment 21•21 years ago
|
||
Comment on attachment 142506 [details] [diff] [review]
Patch
- In nsDocument::CreateCDATASection():
+ if (FindInReadable(NS_LITERAL_STRING("]]>"),begin,end))
+ return NS_ERROR_DOM_INVALID_CHARACTER_ERR;
This is not per the DOM spec, but I know you didn't write this now... At some
point we should allow this, and let people catch silly stuff like this in
normalizeDocument() or while serializing.
r+sr=jst
Attachment #142506 -
Flags: superreview?(jst)
Attachment #142506 -
Flags: superreview+
Attachment #142506 -
Flags: review?(jst)
Attachment #142506 -
Flags: review+
![]() |
Assignee | |
Updated•21 years ago
|
Assignee: general → bzbarsky
Priority: P5 → P3
Target Milestone: Future → mozilla1.7beta
![]() |
Assignee | |
Comment 22•21 years ago
|
||
Fixed.
Status: NEW → RESOLVED
Closed: 24 years ago → 21 years ago
Resolution: --- → FIXED
Comment 23•21 years ago
|
||
bz:
Is it possible that this patch caused the OS/2 bustage (see
http://tinderbox.mozilla.org/showlog.cgi?log=SeaMonkey-Ports/1078267320.4475.gz) ?
![]() |
Assignee | |
Comment 24•21 years ago
|
||
That tbox is testing a beta compiler that was pretty clearly miscompiling
Mozilla (oragne and all) even before it went red. The bustage seems to be that
it's just not linking the right things together (notice that it can't find nice
things like operator new for parts of the code that are nowhere near what this
patch touches).
Comment 25•21 years ago
|
||
I'm in the process of building the latest code on OS/2. I've just gotten past
layout, and it built the DLL just fine (I am also using this beta compiler). So
for the moment, it looks like it was a machine error.
Component: DOM: Core → DOM: Core & HTML
QA Contact: stummala → general
You need to log in
before you can comment on or make changes to this bug.
Description
•