<?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>7143</bug_id>
          
          <creation_ts>2006-02-08 11:53:51 -0800</creation_ts>
          <short_desc>REGRESSION: onclick handler cannot call a function named OnClick</short_desc>
          <delta_ts>2006-03-22 12:13:58 -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>DOM</component>
          <version>420+</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, Regression</keywords>
          <priority>P1</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Alexey Proskuryakov">ap</reporter>
          <assigned_to name="Darin Adler">darin</assigned_to>
          <cc>alice.barraclough</cc>
    
    <cc>darin</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>31853</commentid>
    <comment_count>0</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2006-02-08 11:53:51 -0800</bug_when>
    <thetext>Steps to reproduce: open the attached test case, click on the text.

Expected results: an alert appears.
Actual results: nothing happens.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>31854</commentid>
    <comment_count>1</comment_count>
      <attachid>6345</attachid>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2006-02-08 11:54:41 -0800</bug_when>
    <thetext>Created attachment 6345
test case

Error message:
Value OnClick(); (result of expression OnClick) is not object.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>31906</commentid>
    <comment_count>2</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-02-08 21:03:49 -0800</bug_when>
    <thetext>For some reason, we have an onclick property on DOM nodes that allows you to set and get the onclick handle for a DOM node. I can&apos;t find any other web browser that has this property.

Because of this property, when you try to call a function on the window object named onclick, you find the property on the DOM node first.

The fix is presumably just to remove the property, but I would like to know why the property is there, and how many of the other &quot;onxxx&quot; properties need to be removed.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>31908</commentid>
    <comment_count>3</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-02-08 21:08:22 -0800</bug_when>
    <thetext>Removing the properties from kjs_dom.cpp is going to be easy. The only hard thing here is testing with other browsers to see whether they have properties like ours.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>32294</commentid>
    <comment_count>4</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-02-12 21:55:43 -0800</bug_when>
    <thetext>Maciej thinks my analysis is wrong and this is really about case sensitivity. I think he&apos;s right and my tests of other browsers were confused. I&apos;ll look into a fix given that insight.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>33377</commentid>
    <comment_count>5</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-02-19 09:32:17 -0800</bug_when>
    <thetext>I now believe that fixing this is as simple as changing the getAttribute calls in KJS::DOMElement::getOwnPropertySlot and KJS::DOMElement::attributeGetter in kjs_dom.cpp. Either we remove them entirely or we change them to construct a QualifiedName directly to avoid the lower-casing that&apos;s done in WebCore::ElementImpl::getAttributeNS.

The argument for removing them entirely is that they implement a feature that is not present in Gecko/Firefox. The argument for keeping them is that they implement a feature that is similar to something present in Internet Explorer.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>37002</commentid>
    <comment_count>6</comment_count>
    <who name="Alice Liu">alice.barraclough</who>
    <bug_when>2006-03-20 07:10:26 -0800</bug_when>
    <thetext>&lt;rdar://problem/4483856&gt;</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>6345</attachid>
            <date>2006-02-08 11:54:41 -0800</date>
            <delta_ts>2006-02-08 11:54:41 -0800</delta_ts>
            <desc>test case</desc>
            <filename>onclick.html</filename>
            <type>text/html</type>
            <size>167</size>
            <attacher name="Alexey Proskuryakov">ap</attacher>
            
              <data encoding="base64">PGh0bWw+DQo8aGVhZD4NCjxzY3JpcHQ+DQpmdW5jdGlvbiBPbkNsaWNrKCkNCnsNCiAgYWxlcnQo
MCk7DQp9DQo8L3NjcmlwdD4NCjwvaGVhZD4NCjxib2R5Pg0KPGRpdiBvbmNsaWNrPSJPbkNsaWNr
KCk7Ij5DbGljayB0byB0ZXN0IG9uY2xpY2suPC9kaXY+DQo8L2JvZHk+DQo8L2h0bWw+DQo=
</data>

          </attachment>
      

    </bug>

</bugzilla>