<?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>3524</bug_id>
          
          <creation_ts>2005-06-14 04:57:03 -0700</creation_ts>
          <short_desc>View Source shows nothing when creating a window with no URL using js</short_desc>
          <delta_ts>2017-11-18 00:26:51 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebKit Misc.</component>
          <version>412</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.4</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>HasReduction, InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Rob Buis">rwlbuis</reporter>
          <assigned_to name="Maciej Stachowiak">mjs</assigned_to>
          <cc>andersca</cc>
    
    <cc>ap</cc>
    
    <cc>dbates</cc>
    
    <cc>eric</cc>
    
    <cc>keving</cc>
    
    <cc>pfeldman</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>11865</commentid>
    <comment_count>0</comment_count>
    <who name="Rob Buis">rwlbuis</who>
    <bug_when>2005-06-14 04:57:10 -0700</bug_when>
    <thetext>To reproduce:

1. go to http://ip30.eti.uva.nl/zma3d/sittidae.html
2. Click on either small/medium/large size
3. The popped up window doesnt get a title, just &quot;Untitled&quot;

Works in FireFox, so I assume it is valid js.
The js method to create the doc is:

xWin.document.write(&quot;&lt;html&gt;&lt;head&gt;&lt;title&gt;&quot; + pagetitle + &quot;&lt;/title&gt;...

Cheers,

Rob.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11873</commentid>
    <comment_count>1</comment_count>
    <who name="Joost de Valk (AlthA)">joost</who>
    <bug_when>2005-06-14 05:53:27 -0700</bug_when>
    <thetext>Confirmed, works on firefox, doesn&apos;t on current ToT.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11875</commentid>
    <comment_count>2</comment_count>
    <who name="Joost de Valk (AlthA)">joost</who>
    <bug_when>2005-06-14 05:54:00 -0700</bug_when>
    <thetext>*** Bug 3523 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12112</commentid>
    <comment_count>3</comment_count>
      <attachid>2359</attachid>
    <who name="Anders Carlsson">andersca</who>
    <bug_when>2005-06-15 06:01:36 -0700</bug_when>
    <thetext>Created attachment 2359
Isolated test case

Here&apos;s an isolated test case that shows the bug.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12113</commentid>
    <comment_count>4</comment_count>
    <who name="Anders Carlsson">andersca</who>
    <bug_when>2005-06-15 06:03:44 -0700</bug_when>
    <thetext>Both the test case and the web page work in MiniBrowser which is shipped with Xcode as a WebKit 
example, which makes it look like the bug might be in Safari itself.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12161</commentid>
    <comment_count>5</comment_count>
      <attachid>2359</attachid>
    <who name="John Sullivan">sullivan</who>
    <bug_when>2005-06-15 16:53:48 -0700</bug_when>
    <thetext>Comment on attachment 2359
Isolated test case

Two more aspects of this test case seem broken, at least in Safari:
(1) &quot;View Source&quot; on the javascript-created window shows nothing at all
(2) Reload on the javascript-created window hits an assertion on debug builds.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12162</commentid>
    <comment_count>6</comment_count>
    <who name="John Sullivan">sullivan</who>
    <bug_when>2005-06-15 16:58:06 -0700</bug_when>
    <thetext>Also, in the test case, there&apos;s no URL showing in the address bar at all for the javascript-created window. 
(In Firefox it shows the URL of the originating page, which is differently wrong.)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12163</commentid>
    <comment_count>7</comment_count>
    <who name="John Sullivan">sullivan</who>
    <bug_when>2005-06-15 17:18:26 -0700</bug_when>
    <thetext>I&apos;ve confirmed that the missing title is a Safari-specific issue. It&apos;s related to the missing URL, but I haven&apos;t 
figured out yet whether the missing URL is a Safari-specific issue or not. We don&apos;t use Bugzilla for Safari-
specific issues since Safari isn&apos;t open source, but I&apos;ll leave this one open for now until I determine whether 
any of the other aspects of this bug are WebKit issues.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12217</commentid>
    <comment_count>8</comment_count>
    <who name="Ruud Altenburg">ruud</who>
    <bug_when>2005-06-16 00:56:13 -0700</bug_when>
    <thetext>FYI: I have reported this issue a long time ago as a regression in Safari (using the Report a bug... option). 
Safari 1.0.2 displays the title but NOT the source. </thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12240</commentid>
    <comment_count>9</comment_count>
    <who name="John Sullivan">sullivan</who>
    <bug_when>2005-06-16 08:40:40 -0700</bug_when>
    <thetext>OK, thanks Ruud. I&apos;ll look for an old Radar bug about this. I think not displaying the source is closely 
related to not displaying the title and not showing any URL.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12257</commentid>
    <comment_count>10</comment_count>
    <who name="John Sullivan">sullivan</who>
    <bug_when>2005-06-16 11:46:59 -0700</bug_when>
    <thetext>I couldn&apos;t find any existing Radar bug on this issue; presumably I didn&apos;t do the right search. I wrote up new 
radar bugs to represent the various problems here. Most of them seem to be Safari-specific bugs. The 
only one that currently seems to be a WebKit bug is the fact that View Source shows an empty window. I&apos;m 
seeing [[datasource representation] documentSource] return nil here. So I&apos;m going to repurpose this bug 
report to represent the empty Source bug, since Safari-specific bugs aren&apos;t tracked in Bugzilla.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12258</commentid>
    <comment_count>11</comment_count>
    <who name="John Sullivan">sullivan</who>
    <bug_when>2005-06-16 11:47:34 -0700</bug_when>
    <thetext>The radar bug that tracks this View Source issue is 4150996.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12443</commentid>
    <comment_count>12</comment_count>
    <who name="John Sullivan">sullivan</who>
    <bug_when>2005-06-17 09:41:43 -0700</bug_when>
    <thetext>[WebHTMLRepresentation documentSource] returns a string created from [_private-&gt;dataSource data]. 
[WebDataSource data] returns a field that&apos;s set in [WebDataSource _setData:], called from 
[WebDataSource _setPrimaryLoadComplete:].

In this case the &quot;primary load&quot; is meaningless, as it&apos;s just opening a window with an empty URL. There is 
no data there. The only contents of the page are created by document.write() calls, but this content 
doesn&apos;t make it into the datasource&apos;s data field.

I&apos;m not an expert in this area, and I haven&apos;t investigated how else the data field is used. We either need 
to make it contain document.write()-generated code, or make the documentSource call work a different 
way for this case at least. I&apos;m handing this off to Chris, but if anyone else wants to work on it they 
should feel free.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>31874</commentid>
    <comment_count>13</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2006-02-08 12:35:52 -0800</bug_when>
    <thetext>*** Bug 4753 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>798271</commentid>
    <comment_count>14</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2012-12-30 17:09:44 -0800</bug_when>
    <thetext>&quot;view source&quot; is simply disabled for Chrome in this case.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1373516</commentid>
    <comment_count>15</comment_count>
    <who name="Maciej Stachowiak">mjs</who>
    <bug_when>2017-11-18 00:26:51 -0800</bug_when>
    <thetext>Classic View Source is gone. The Web Inspector lets you see them DOM now. I&apos;d consider this fixed.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>2359</attachid>
            <date>2005-06-15 06:01:36 -0700</date>
            <delta_ts>2005-06-15 06:01:36 -0700</delta_ts>
            <desc>Isolated test case</desc>
            <filename>test.html</filename>
            <type>text/html</type>
            <size>282</size>
            <attacher name="Anders Carlsson">andersca</attacher>
            
              <data encoding="base64">PGh0bWw+CjxzY3JpcHQ+CmZ1bmN0aW9uIG9wZW53aW4oKSB7Cgl2YXIgdyA9IHdpbmRvdy5vcGVu
KCk7CgkKCXcuZG9jdW1lbnQub3BlbigpOwoJdy5kb2N1bWVudC53cml0ZSgnPGh0bWw+PGhlYWQ+
PHRpdGxlPlRoaXMgaXMgYSB0aXRsZTwvdGl0bGU+PC9oZWFkPjxib2R5PmZvbzwvYm9keT48L2h0
bWw+Jyk7Cgl3LmRvY3VtZW50LmNsb3NlKCk7Cn0KCjwvc2NyaXB0Pgo8aW5wdXQgdHlwZT0iYnV0
dG9uIiB2YWx1ZT0ib3BlbiB3aW5kb3ciIG9uQ2xpY2s9Im9wZW53aW4oKTsiPgo8L2h0bWw+
</data>

          </attachment>
      

    </bug>

</bugzilla>