<?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>17193</bug_id>
          
          <creation_ts>2008-02-06 04:50:35 -0800</creation_ts>
          <short_desc>Attributes of &lt;input type=range&gt; not accessable from javascript</short_desc>
          <delta_ts>2019-10-16 11:12:05 -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>523.x (Safari 3)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>CONFIGURATION CHANGED</resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=202859</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>HasReduction</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Sascha">saschast</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ap</cc>
    
    <cc>ddkilzer</cc>
    
    <cc>ian</cc>
    
    <cc>joepeck</cc>
    
    <cc>phistuck</cc>
    
    <cc>thorton</cc>
    
    <cc>wenson_hsieh</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>69560</commentid>
    <comment_count>0</comment_count>
    <who name="Sascha">saschast</who>
    <bug_when>2008-02-06 04:50:35 -0800</bug_when>
    <thetext>The min and max attributes of the &lt;input type=range&gt; element can not read from a javascript.
Make somthing like this:        a = input_el.min;         it only return &quot;undefined&quot;

I have this tested and confirmed on 10.4.11 Safari3, Win XP Safari3beta and Win XP Safari3beta +Nightly r29908

I think internaly it is used because if youset the element&apos;s value to a out-of-bound the value is set to the min/max boundary.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>69561</commentid>
    <comment_count>1</comment_count>
      <attachid>18959</attachid>
    <who name="Sascha">saschast</who>
    <bug_when>2008-02-06 04:52:35 -0800</bug_when>
    <thetext>Created attachment 18959
test of min/max attributes of &lt;input type=range&gt; element</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>69563</commentid>
    <comment_count>2</comment_count>
    <who name="Sascha">saschast</who>
    <bug_when>2008-02-06 05:12:43 -0800</bug_when>
    <thetext>Additional Info:
This problem also leads to a not functionality in Safaris RSS viewer. If you cklick the images on left/right of the scale slider result in no reaction.
I have made a little patch on my own Safari (windows) and it works. I only add a test if the attribute is set
or initalize it with it boundaries.
File: Articles.js
Location on Windows: Safari/PubSub.resources/Articles.js
Patch:
1171,1172d1170
&lt;     if (slider.min == undefined)
&lt;         slider.min = 0;
1177,1178d1174
&lt;     if (slider.max == undefined)
&lt;         slider.max = 100;
</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>69564</commentid>
    <comment_count>3</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2008-02-06 05:41:35 -0800</bug_when>
    <thetext>Why is this a bug? HTMLInputElement interface definition does not specify that these attributes should be available as properties AFAICT.

One can use getAttribute() and related DOM methods to manipulate element attributes.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>69565</commentid>
    <comment_count>4</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2008-02-06 05:52:49 -0800</bug_when>
    <thetext>(In reply to comment #2)
&gt; This problem also leads to a not functionality in Safaris RSS viewer.

Thank you! Filed as &lt;rdar://problem/5727306&gt;.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>86675</commentid>
    <comment_count>5</comment_count>
    <who name="David Kilzer (:ddkilzer)">ddkilzer</who>
    <bug_when>2008-07-22 14:11:42 -0700</bug_when>
    <thetext>Web Forms 2.0 doesn&apos;t mention anything about including &quot;min&quot; and &quot;max&quot; as DOM attributes:

http://www.whatwg.org/specs/web-forms/current-work/#ranges
</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>201085</commentid>
    <comment_count>6</comment_count>
    <who name="Joseph Pecoraro">joepeck</who>
    <bug_when>2010-03-17 17:54:09 -0700</bug_when>
    <thetext>This now works correctly if you have explicitly provided min/max attribute values. However, it doesn&apos;t seem to work with the defaults, which are 0 and 100 for an &lt;input type=range&gt;. I am going to leave this open for that reason.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1578713</commentid>
    <comment_count>7</comment_count>
    <who name="PhistucK">phistuck</who>
    <bug_when>2019-10-10 10:29:59 -0700</bug_when>
    <thetext>I think this can be closed. When not explicitly specifying the min and max, all of the browsers I tested (Firefox, Safari and Chrome) behave the same - min and max have empty strings as their values.

On the other hand, a bit unrelated, you may want to port this patch perhaps -
https://bugs.chromium.org/p/chromium/issues/detail?id=852938#c7</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1579150</commentid>
    <comment_count>8</comment_count>
    <who name="David Kilzer (:ddkilzer)">ddkilzer</who>
    <bug_when>2019-10-11 10:48:33 -0700</bug_when>
    <thetext>(In reply to PhistucK from comment #7)
&gt; I think this can be closed. When not explicitly specifying the min and max,
&gt; all of the browsers I tested (Firefox, Safari and Chrome) behave the same -
&gt; min and max have empty strings as their values.
&gt; 
&gt; On the other hand, a bit unrelated, you may want to port this patch perhaps -
&gt; https://bugs.chromium.org/p/chromium/issues/detail?id=852938#c7

Could you file a separate bug for the UI not updating when calling setAttribute()?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1579182</commentid>
    <comment_count>9</comment_count>
    <who name="PhistucK">phistuck</who>
    <bug_when>2019-10-11 11:55:46 -0700</bug_when>
    <thetext>Done. Bug 202859.
This one can be closed.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>18959</attachid>
            <date>2008-02-06 04:52:35 -0800</date>
            <delta_ts>2008-02-06 04:52:35 -0800</delta_ts>
            <desc>test of min/max attributes of &lt;input type=range&gt; element</desc>
            <filename>slider_test.html</filename>
            <type>text/html</type>
            <size>734</size>
            <attacher name="Sascha">saschast</attacher>
            
              <data encoding="base64">PGh0bWw+DQo8aGVhZD4NCjxzY3JpcHQ+DQp2YXIgdmFsID0gNTsNCmZ1bmN0aW9uIGxvZyhtc2cp
IHsgZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoJ2xvZycpLmFwcGVuZENoaWxkKGRvY3VtZW50LmNy
ZWF0ZVRleHROb2RlKG1zZyArICdcbicpKTsgfQ0KZnVuY3Rpb24gdGVzdCgpIHsgZG9jdW1lbnQu
Z2V0RWxlbWVudHNCeVRhZ05hbWUoJ2lucHV0JylbMF0udmFsdWUgPSAyMDA7IH0NCjwvc2NyaXB0
Pg0KPC9oZWFkPg0KPGJvZHk+DQo8cD5UaGlzIHBhZ2UgdGVzdHMgdGhhdCB0aGUgbWluIGFuZCBt
YXggYXR0cmlidXRlcyBvZiBhbiA8dHQ+Jmx0O2lucHV0IHR5cGU9cmFuZ2UmZ3Q7PC90dD4gZWxl
bWVudCBpcyBub3QgYWNjZXNzYWJsZSB3aXRoIEphdmFzY3JpcHQuPGJyIC8+DQpJbnRlcm5hbCB0
aGV5IGFyZSB1c2VkIGJlY2F1c2UgaWYgeW91IHNldCB0aGUgdmFsdWUgdG8gYW4gb3V0LW9mLXJh
bmdlIHZhbHVlIHRoZSB2YWx1ZSBpcyBzZXQgdG8gdGhlbWluIG9yIG1heCBib3VuZGFyeS4gPC9w
Pg0KPGlucHV0IHR5cGU9InJhbmdlIiBvbmlucHV0PSJsb2coJ1ZhbHVlOiAnICsgdGhpcy52YWx1
ZSArICcsIE1pbjogJyArIHRoaXMubWluICsgJywgTWF4OiAnICsgdGhpcy5tYXgpIiBtaW49IjAi
IG1heD0iMTAwIiB2YWx1ZT0iNTAiPg0KPGJ1dHRvbiBvbmNsaWNrPSJ0ZXN0KCkiPkNsaWNrIG1l
ITwvYnV0dG9uPg0KPHByZSBpZD0ibG9nIj48L3ByZT4NCjwvYm9keT4NCjwvaHRtbD4=
</data>

          </attachment>
      

    </bug>

</bugzilla>