<?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>8550</bug_id>
          
          <creation_ts>2009-12-25 19:20:23 +0000</creation_ts>
          <short_desc>Add document.createElement(&quot;&lt;div&gt;&quot;) (Gecko quirks, IE)? [ms]</short_desc>
          <delta_ts>2010-10-04 13:59:52 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>HTML WG</product>
          <component>pre-LC1 HTML5 spec (editor: Ian Hickson)</component>
          <version>unspecified</version>
          <rep_platform>Other</rep_platform>
          <op_sys>other</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>WORKSFORME</resolution>
          
          
          <bug_file_loc>http://www.whatwg.org/specs/web-apps/current-work/#apis-in-html-documents</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P3</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>LC</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>contributor</reporter>
          <assigned_to name="Ian &apos;Hixie&apos; Hickson">ian</assigned_to>
          <cc>annevk</cc>
    
    <cc>hsivonen</cc>
    
    <cc>ian</cc>
    
    <cc>jonas</cc>
    
    <cc>mike</cc>
    
    <cc>mjs</cc>
    
    <cc>Ms2ger</cc>
    
    <cc>public-html-admin</cc>
    
    <cc>public-html-wg-issue-tracking</cc>
          
          <qa_contact name="HTML WG Bugzilla archive list">public-html-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>30249</commentid>
    <comment_count>0</comment_count>
    <who name="">contributor</who>
    <bug_when>2009-12-25 19:20:23 +0000</bug_when>
    <thetext>Section: http://www.whatwg.org/specs/web-apps/current-work/#apis-in-html-documents

Comment:
Add document.createElement(&quot;&lt;div&gt;&quot;) (Gecko quirks, IE)? [ms]

Posted from: 91.180.133.13</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30279</commentid>
    <comment_count>1</comment_count>
    <who name="Simon Pieters">zcorpan</who>
    <bug_when>2009-12-28 10:11:35 +0000</bug_when>
    <thetext>Have you found a need to implement this in WebKit?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30454</commentid>
    <comment_count>2</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2010-01-05 07:15:02 +0000</bug_when>
    <thetext>I&apos;m not convinced we need to do this. I rather have it fixed in Gecko/WebKit.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30665</commentid>
    <comment_count>3</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2010-01-06 12:12:58 +0000</bug_when>
    <thetext>Can we file bugs on Gecko/WebKit for this?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30681</commentid>
    <comment_count>4</comment_count>
    <who name="Maciej Stachowiak">mjs</who>
    <bug_when>2010-01-06 19:34:17 +0000</bug_when>
    <thetext>WebKit does not support this functionality. I&apos;m not sure why it&apos;s mentioned here.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30685</commentid>
    <comment_count>5</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2010-01-06 21:37:42 +0000</bug_when>
    <thetext>Because you filed the bug. My bad.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30686</commentid>
    <comment_count>6</comment_count>
    <who name="Maciej Stachowiak">mjs</who>
    <bug_when>2010-01-06 22:04:06 +0000</bug_when>
    <thetext>I don&apos;t think it was me - I never file bugs through the comment form.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30687</commentid>
    <comment_count>7</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2010-01-06 22:08:54 +0000</bug_when>
    <thetext>Oh, is ms Mike Smith?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30688</commentid>
    <comment_count>8</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2010-01-06 22:45:30 +0000</bug_when>
    <thetext>Ok, I&apos;ll file a bug on the UAs that do this and then reject this, unless anyone objects.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30691</commentid>
    <comment_count>9</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2010-01-07 05:55:23 +0000</bug_when>
    <thetext>EDITOR&apos;S RESPONSE: This is an Editor&apos;s Response to your comment. If you are satisfied with this response, please change the state of this bug to CLOSED. If you have additional information and would like the editor to reconsider, please reopen this bug. If you would like to escalate the issue to the full HTML Working Group, please add the TrackerRequest keyword to this bug, and suggest title and text for the tracker issue; or you may create a tracker issue yourself, if you are able to do so. For more details, see this document:
   http://dev.w3.org/html5/decision-policy/decision-policy.html

Status: Rejected
Change Description: no spec change
Rationale: Only IE seems to do this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30703</commentid>
    <comment_count>10</comment_count>
    <who name="Henri Sivonen">hsivonen</who>
    <bug_when>2010-01-07 08:51:21 +0000</bug_when>
    <thetext>(In reply to comment #9)
&gt; Rationale: Only IE seems to do this.

FWIW, Gecko supports document.createElement(&quot;&lt;div&gt;&quot;) in the quirks mode. It doesn&apos;t support specifying attributes on the pseudo-tag and doesn&apos;t support this variant in the Almost Standards and Standards modes.
http://software.hixie.ch/utilities/js/live-dom-viewer/saved/345
http://hg.mozilla.org/mozilla-central/file/abb82f981e02/content/html/document/src/nsHTMLDocument.cpp#l1225

The rationale for adding support was compat with IBM enterprise apps.
https://bugzilla.mozilla.org/show_bug.cgi?id=245274</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30705</commentid>
    <comment_count>11</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2010-01-07 09:06:04 +0000</bug_when>
    <thetext>Would Gecko be willing to remove support?
Would Webkit/Opera be willing to add support?

If we add support, can we do it in all modes? I really don&apos;t like mode differences, because, as demonstrated above, they are confusing.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30706</commentid>
    <comment_count>12</comment_count>
    <who name="Maciej Stachowiak">mjs</who>
    <bug_when>2010-01-07 09:32:23 +0000</bug_when>
    <thetext>(In reply to comment #11)
&gt; Would Gecko be willing to remove support?
&gt; Would Webkit/Opera be willing to add support?
&gt; 
&gt; If we add support, can we do it in all modes? I really don&apos;t like mode
&gt; differences, because, as demonstrated above, they are confusing.
&gt; 

If the quirk is truly necessary for Web compatibility, then I would not be opposed. A few notes though:

1) The Safari team gets a lot of input on enterprise Web apps, including those produced by IBM. These are usually high visibility compared to the average Web compat bug. So perhaps this usage was never that common and/or has faded.

2) Should createelement(&quot;&lt;div&gt;&quot;) make an element with tagName &quot;div&quot; or tagName &quot;&lt;div&gt;&quot;? In Mozilla it is the former, in IE the latter, supposedly either was good enough for the enterprise Web apps that depended on this in 2004.

3) In general I prefer not to have quirks mode switches in the DOM. On the other hand, making an element with &lt; or &gt; in its name is pretty bogus, and results in an unserializable document, so perhaps in this case quirks-only is justifiable.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30708</commentid>
    <comment_count>13</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2010-01-07 10:06:40 +0000</bug_when>
    <thetext>I filed https://bugzilla.mozilla.org/show_bug.cgi?id=489532 a while ago.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>30737</commentid>
    <comment_count>14</comment_count>
    <who name="Jonas Sicking (Not reading bugmail)">jonas</who>
    <bug_when>2010-01-07 19:07:20 +0000</bug_when>
    <thetext>(In reply to comment #12)
&gt; 2) Should createelement(&quot;&lt;div&gt;&quot;) make an element with tagName &quot;div&quot; or tagName
&gt; &quot;&lt;div&gt;&quot;? In Mozilla it is the former, in IE the latter, supposedly either was
&gt; good enough for the enterprise Web apps that depended on this in 2004.

This does not match my testing. Both gecko and IE create an element with tagName &quot;div&quot; for document.createElement(&quot;&lt;div&quot;);

IE even supports
document.createElement(&quot;&lt;div class=foo&gt;&quot;);

which creates an element with a className of &quot;foo&quot;. (any other attribute works equally well). Gecko does not support this attribute syntax though.

I guess I don&apos;t feel strongly here. I&apos;d be fine with attempting to remove this quirk from gecko. Dunno how much success we&apos;ll have with convincing Microsoft of the same though.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>36977</commentid>
    <comment_count>15</comment_count>
    <who name="Ms2ger">Ms2ger</who>
    <bug_when>2010-07-17 09:45:22 +0000</bug_when>
    <thetext>The quirk was removed in Gecko: &lt;http://hg.mozilla.org/mozilla-central/rev/ecdf587c02d0&gt;.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>