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

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>14750</bug_id>
          
          <creation_ts>2011-11-10 08:23:17 +0000</creation_ts>
          <short_desc>Clarify what the origin of the new document is if the document is blown away (consider if the old document set document.domain)</short_desc>
          <delta_ts>2012-07-18 18:49:00 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WHATWG</product>
          <component>HTML</component>
          <version>unspecified</version>
          <rep_platform>Other</rep_platform>
          <op_sys>other</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WORKSFORME</resolution>
          
          
          <bug_file_loc>http://www.whatwg.org/specs/web-apps/current-work/#document.write()</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P3</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>Unsorted</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>contributor</reporter>
          <assigned_to name="Ian &apos;Hixie&apos; Hickson">ian</assigned_to>
          <cc>ian</cc>
    
    <cc>mike</cc>
    
    <cc>zcorpan</cc>
          
          <qa_contact>contributor</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>59818</commentid>
    <comment_count>0</comment_count>
    <who name="">contributor</who>
    <bug_when>2011-11-10 08:23:17 +0000</bug_when>
    <thetext>Specification: http://www.whatwg.org/specs/web-apps/current-work/multipage/elements.html
Multipage: http://www.whatwg.org/C#document.write()
Complete: http://www.whatwg.org/c#document.write()

Comment:
Clarify what the origin of the new document is if the document is blown away
(consider if the old document set document.domain)

Posted from: 85.227.157.105 by simonp@opera.com
User agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_5_8) AppleWebKit/535.8 (KHTML, like Gecko) Chrome/17.0.932.0 Safari/535.8</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>59872</commentid>
    <comment_count>1</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2011-11-11 00:03:26 +0000</bug_when>
    <thetext>Can you elaborate? Do you have an example of what you have in mind?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>59897</commentid>
    <comment_count>2</comment_count>
    <who name="Simon Pieters">zcorpan</who>
    <bug_when>2011-11-11 07:16:26 +0000</bug_when>
    <thetext>http://example.org

&lt;iframe src=http://foo.example.org/&gt;&lt;/iframe&gt;
&lt;script&gt;
document.domain = &apos;example.org&apos;;
onload = function(){
  window[0].document.write(&apos;foo&apos;);
}
&lt;/script&gt;


http://foo.example.org

&lt;script&gt;
document.domain = &apos;example.org&apos;;
&lt;/script&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61171</commentid>
    <comment_count>3</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2011-12-07 23:35:36 +0000</bug_when>
    <thetext>Isn&apos;t the document recycled in that case? Thus the origin doesn&apos;t change?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61224</commentid>
    <comment_count>4</comment_count>
    <who name="Simon Pieters">zcorpan</who>
    <bug_when>2011-12-08 09:27:57 +0000</bug_when>
    <thetext>&quot;Unload the Document object, with the recycle parameter set to true.&quot;

So, yes. For some reason this wasn&apos;t clear to me when I filed the bug. It was clear when I read it now, so closing.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>