<?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>25397</bug_id>
          
          <creation_ts>2009-04-25 13:00:48 -0700</creation_ts>
          <short_desc>document.write to an image document fails</short_desc>
          <delta_ts>2018-09-24 15:17:00 -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>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=189917</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Alexey Proskuryakov">ap</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>andersca</cc>
    
    <cc>eric</cc>
    
    <cc>ian</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>118848</commentid>
    <comment_count>0</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2009-04-25 13:00:48 -0700</bug_when>
    <thetext>Trying to write into an image document (e.g. &lt;iframe src=&quot;image.gif&gt;) fails with an assertion in debug builds, and is just ignored in release builds.

It seems that we shouldn&apos;t subclass HTMLDocument, as all HTML documents need to support writing HTML content in them. This affects LexisNexis (requires an account to reproduce).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>118882</commentid>
    <comment_count>1</comment_count>
      <attachid>29798</attachid>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2009-04-25 22:09:26 -0700</bug_when>
    <thetext>Created attachment 29798
test case (will assert)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>170820</commentid>
    <comment_count>2</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2009-12-11 10:27:29 -0800</bug_when>
    <thetext>This no longer fails with an assertion as of r51997, but it doesn&apos;t work either.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>242340</commentid>
    <comment_count>3</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2010-06-24 00:05:14 -0700</bug_when>
    <thetext>Seems document.write should just be ignored for image documents, like how it is for XML.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>242345</commentid>
    <comment_count>4</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2010-06-24 00:13:13 -0700</bug_when>
    <thetext>Is this what HTML5 now says? My understanding was that document.write() is supposed to behave exactly the same as it does for any HTML documents.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>242348</commentid>
    <comment_count>5</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2010-06-24 00:16:19 -0700</bug_when>
    <thetext>HTML5 throws an exception in XML docs:
http://www.whatwg.org/specs/web-apps/current-work/multipage/apis-in-html-documents.html#document.write()

But doesn&apos;t talk about image documents.  Perhaps those need to have the generic write handling.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>29798</attachid>
            <date>2009-04-25 22:09:26 -0700</date>
            <delta_ts>2009-04-25 22:09:26 -0700</delta_ts>
            <desc>test case (will assert)</desc>
            <filename>write-to-image-document.html</filename>
            <type>text/html</type>
            <size>491</size>
            <attacher name="Alexey Proskuryakov">ap</attacher>
            
              <data encoding="base64">PGJvZHkgb25sb2FkPSJ0ZXN0KCkiPgo8cD5TaG91bGQgc2F5IFNVQ0NFU1M6PC9wPgo8aWZyYW1l
IHNyYz0iZGF0YTppbWFnZS9naWY7YmFzZTY0LFIwbEdPRGxoRUFBT0FMTUFBT2F6VG9lSGgwdExT
LzdMWnYvMGp2YjI5dC9mMy8vVWIvL2dlOFdTTGYvcmhmLzNrZGJXMW14c2JQLy9tZi8vL3lINUJB
QUFBQUFBTEFBQUFBQVFBQTRBQUFSZThMMUVreWt5NjdRWjFoTG5qTTVVVWRlMEVDd0xKb0V4S2Nw
cFYwYUNjR0NtVElIRUlVRXFqZ2FPUkNNeElDNmUwQ2NndVd3NmFGanNWTWtrSXI3Zzc3WktQSmpQ
WnFJeWQ3c0pBZ1ZHb0VHdjJ4c0J4cU5nWVBqL2dBd1hFUUE3Ij48L2lmcmFtZT4KPHNjcmlwdD4K
ZnVuY3Rpb24gdGVzdCgpCnsKICAgIGZyYW1lc1swXS5kb2N1bWVudC5vcGVuKCk7CiAgICBmcmFt
ZXNbMF0uZG9jdW1lbnQud3JpdGUoIjxwPlNVQ0NFU1M8L3A+Iik7CiAgICBmcmFtZXNbMF0uZG9j
dW1lbnQuY2xvc2UoKTsKfQo8L3NjcmlwdD4KPC9ib2R5Pgo=
</data>

          </attachment>
      

    </bug>

</bugzilla>