<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>12339</bug_id>
          
          <creation_ts>2007-01-19 22:24:22 -0800</creation_ts>
          <short_desc>XML DOM operations involving two documents don&apos;t match IE/Firefox behavior</short_desc>
          <delta_ts>2022-08-05 15:16:48 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>DOM</component>
          <version>420+</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.4</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>CONFIGURATION CHANGED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>10489</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Jesse Costello-Good">jesse</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ahmad.saleem792</cc>
    
    <cc>ap</cc>
    
    <cc>bfulgham</cc>
    
    <cc>cdumez</cc>
    
    <cc>rniwa</cc>
    
    <cc>spocke</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>34163</commentid>
    <comment_count>0</comment_count>
    <who name="Jesse Costello-Good">jesse</who>
    <bug_when>2007-01-19 22:24:22 -0800</bug_when>
    <thetext>I think that Safari probably has the more spec-compliant implementation but I report this for the sake of cross-browser AJAX compatibility.

appendChild, insertBefore, replaceChild, and setAttributeNode (could there be more?) fail when the argument is a node from a different XML document. In IE and Fx these methods behave as though the nodes are in the same document. No special logic is necessary to test whether the ownerDocument property of the two nodes is the same.

The work around is to use importNode(), call one of the above methods passing in the imported node, and remove the argument node from its parent node in the other document.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>22956</commentid>
    <comment_count>1</comment_count>
    <who name="Maciej Stachowiak">mjs</who>
    <bug_when>2007-02-16 20:48:24 -0800</bug_when>
    <thetext>Our behavior is more spec-compliant. We would consider changing it, but I think Firefox at least is considering changing to match the spec more closely instead</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>109833</commentid>
    <comment_count>2</comment_count>
      <attachid>27689</attachid>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2009-02-16 02:47:02 -0800</bug_when>
    <thetext>Created attachment 27689
test case

On this test case, WebKit and IE7 raise an exception, while Firefox 3.1b2 and Opera 9.63 do not. I&apos;m not sure if that&apos;s the case reported here.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>109834</commentid>
    <comment_count>3</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2009-02-16 02:47:51 -0800</bug_when>
    <thetext>See also: bug 4569.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>142859</commentid>
    <comment_count>4</comment_count>
    <who name="Johan &quot;Spocke&quot; Sörlin">spocke</who>
    <bug_when>2009-08-26 08:33:37 -0700</bug_when>
    <thetext>I don&apos;t think this is a bug. You should use importNode if you want to add a node from one document to another according to W3C specs.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1502951</commentid>
    <comment_count>5</comment_count>
    <who name="Lucas Forschler">lforschler</who>
    <bug_when>2019-02-06 09:03:21 -0800</bug_when>
    <thetext>Mass moving XML DOM bugs to the &quot;DOM&quot; Component.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1889243</commentid>
    <comment_count>6</comment_count>
    <who name="Ahmad Saleem">ahmad.saleem792</who>
    <bug_when>2022-08-05 15:16:37 -0700</bug_when>
    <thetext>I am unable to reproduce this bug based on expected results since the behavior of Safari 15.6 on macOS 12.5 matches with other browsers (Chrome Canary 106 and Firefox Nightly 105) on attached test cases. It shows a dialog box with &quot;P&quot; in it and then show two empty iframe and it is same across all browsers.

Since all browsers are working same, I am going to mark this as &quot;RESOLVED CONFIGURATION CHANGED&quot; expecting that something along the lien fixed it.

In case if I am testing incorrectly, please reopen this bug. Thanks!</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>27689</attachid>
            <date>2009-02-16 02:47:02 -0800</date>
            <delta_ts>2009-02-16 02:47:02 -0800</delta_ts>
            <desc>test case</desc>
            <filename>move-node.html</filename>
            <type>text/html</type>
            <size>449</size>
            <attacher name="Alexey Proskuryakov">ap</attacher>
            
              <data encoding="base64">PGJvZHkgb25sb2FkPSJ0ZXN0KCkiPgo8c2NyaXB0PgpmdW5jdGlvbiB0ZXN0KCkgewogICAgdmFy
IGRvYzEgPSBmcmFtZXNbMF0uZG9jdW1lbnQ7CiAgICB2YXIgZG9jMiA9IGZyYW1lc1sxXS5kb2N1
bWVudDsKICAgIGRvYzIuYm9keS5hcHBlbmRDaGlsZChkb2MyLmNyZWF0ZUVsZW1lbnQoInAiKSk7
CgogICAgdHJ5IHsKICAgICAgICBkb2MxLmJvZHkuYXBwZW5kQ2hpbGQoZG9jMi5ib2R5Lmxhc3RD
aGlsZCk7CiAgICAgICAgYWxlcnQoZG9jMS5ib2R5Lmxhc3RDaGlsZC50YWdOYW1lKTsKICAgIH0g
Y2F0Y2ggKGV4KSB7CiAgICAgICAgYWxlcnQoZXguZGVzY3JpcHRpb24gPyBleC5kZXNjcmlwdGlv
biA6IGV4KTsKICAgIH0KfQo8L3NjcmlwdD4KPGlmcmFtZSBzcmM9ImFib3V0OmJsYW5rIj48L2lm
cmFtZT4KPGlmcmFtZSBzcmM9ImFib3V0OmJsYW5rIj48L2lmcmFtZT4KPC9ib2R5Pgo=
</data>

          </attachment>
      

    </bug>

</bugzilla>