HTML Standard Tracker

Diff (omit for latest revision)
Filter

Short URL: http://html5.org/r/2814

File a bug

SVNBugCommentTime (UTC)
2814[Gecko] [Internet Explorer] [Opera] [Webkit] provide a .value API for <input type=file>2009-02-13 07:32
Index: source
===================================================================
--- source	(revision 2813)
+++ source	(revision 2814)
@@ -28304,7 +28304,7 @@
      <td class="yes"> <span title="dom-input-value-value">value</span> <!-- Color -->
      <td class="yes"> <span title="dom-input-value-default-on">default/on</span> <!-- Checkbox -->
 <!-- <td class="yes"> <span title="dom-input-value-default-on">default/on</span>      Radio Button -->
-     <td class="no"> &middot; <!-- File Upload -->
+     <td class="yes"> <span title="dom-input-value-filename">filename</span> <!-- File Upload -->
      <td class="yes"> <span title="dom-input-value-default">default</span> <!-- Submit Button -->
      <td class="yes"> <span title="dom-input-value-default">default</span> <!-- Image Button -->
      <td class="yes"> <span title="dom-input-value-default">default</span> <!-- Reset Button -->
@@ -30679,6 +30679,9 @@
    <code title="attr-input-multiple">multiple</code>, and
    <code title="attr-input-required">required</code>.</p>
 
+   <p>The <code title="dom-input-value">value</code> DOM attribute is
+   in mode <span title="dom-input-value-filename">filenmae</span>.</p>
+
    <p>The <code title="event-input-change">change</code> event applies.</p>
 
    <p>The following content attributes must not be specified and do not
@@ -30711,7 +30714,6 @@
    <code class="no-backref" title="dom-input-checked">checked</code>,
    <code class="no-backref" title="dom-input-list">list</code>,
    <code class="no-backref" title="dom-input-selectedOption">selectedOption</code>,
-   <code class="no-backref" title="dom-input-value">value</code>,
    <code class="no-backref" title="dom-input-valueAsDate">valueAsDate</code> and
    <code class="no-backref" title="dom-input-valueAsNumber">valueAsNumber</code> DOM attributes;
    <code class="no-backref" title="dom-input-stepDown">stepDown()</code> and
@@ -31680,8 +31682,8 @@
   <p>The <dfn title="dom-input-value"><code>value</code></dfn> DOM
   attribute allows scripts to manipulate the <span
   title="concept-fe-value">value</span> of an <code>input</code>
-  element. If the attribute applies, then it is in one of the
-  following modes, which define its behavior:</p>
+  element. The attribute is in one of the following modes, which
+  define its behavior:</p>
 
   <dl>
 
@@ -31715,11 +31717,17 @@
    title="attr-input-value">value</code> attribute to the new
    value.</dd>
 
+   <dt><dfn title="dom-input-value-filename">filename</dfn>
+
+   <dd>On getting, it must return the string "<code
+   title="">c:\fakepath\</code>" followed by the filename of the first
+   file in the list of <span
+   title="concept-input-type-file-selected">selected files</span>, if
+   any, or the empty string if the list is empty. On setting, it must
+   throw an <code>INVALID_ACCESS_ERR</code> exception.</dd>
+
   </dl>
 
-  <p>If the attribute does not apply, then on getting and setting it
-  must throw an <code>INVALID_ACCESS_ERR</code> exception.</p>
-
   <hr>
 
   <p>The <dfn title="dom-input-checked"><code>checked</code></dfn> DOM

|