Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
[e] (0) <textarea> and <output> examples, plus some minor changes to …
- Loading branch information
Showing
with
50 additions
and
6 deletions.
-
+25
−3
index
-
+25
−3
source
|
|
|
|
|
<div class=example> |
|
|
|
|
|
<p>The following date control limits input to dates that are before |
|
|
the start of the 21st century:</p> |
|
|
the 1980s:</p> |
|
|
|
|
|
<pre><input name=bday type=date max="2000-12-31"></pre> |
|
|
<pre><input name=bday type=date max="1979-12-31"></pre> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
<div class=example> |
|
|
|
|
|
<p>Here is an example of a <code><a href=#the-textarea-element>textarea</a></code> being used for |
|
|
unrestricted free-form text input in a form:</p> |
|
|
|
|
|
<pre><p>If you have any comments, please let us know: <textarea cols=80 name=comments></textarea></p></pre> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<h4 id=the-keygen-element><span class=secno>4.10.11 </span>The <dfn><code>keygen</code></dfn> element</h4> |
|
|
|
|
|
|
|
<pre><form action="processkey.cgi" method="post" enctype="multipart/formdata"> |
|
|
<p><keygen name="key"></p> |
|
|
<p><input type=submit value="Submit key..."> |
|
|
<p><input type=submit value="Submit key..."></p> |
|
|
</form></pre> |
|
|
|
|
|
<p>The server will then receive a form submission with a packaged |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
<div class=example> |
|
|
|
|
|
<p>A simple calculator could use <code><a href=#the-output-element>output</a></code> for its |
|
|
display of calculated results:</p> |
|
|
|
|
|
<pre><form onsubmit="return false"> |
|
|
<input name=a type=number step=any> + |
|
|
<input name=b type=number step=any> = |
|
|
<output onforminput="value = a.value + b.value"></output> |
|
|
</form></pre> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<h4 id=association-of-controls-and-forms><span class=secno>4.10.13 </span>Association of controls and forms</h4> |
|
|
|
|
|
<div class="example"> |
|
|
|
|
|
<p>The following date control limits input to dates that are before |
|
|
the start of the 21st century:</p> |
|
|
the 1980s:</p> |
|
|
|
|
|
<pre><input name=bday type=date max="2000-12-31"></pre> |
|
|
<pre><input name=bday type=date max="1979-12-31"></pre> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="example"> |
|
|
|
|
|
<p>Here is an example of a <code>textarea</code> being used for |
|
|
unrestricted free-form text input in a form:</p> |
|
|
|
|
|
<pre><p>If you have any comments, please let us know: <textarea cols=80 name=comments></textarea></p></pre> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<h4>The <dfn><code>keygen</code></dfn> element</h4> |
|
|
|
|
|
|
|
<pre><form action="processkey.cgi" method="post" enctype="multipart/formdata"> |
|
|
<p><keygen name="key"></p> |
|
|
<p><input type=submit value="Submit key..."> |
|
|
<p><input type=submit value="Submit key..."></p> |
|
|
</form></pre> |
|
|
|
|
|
<p>The server will then receive a form submission with a packaged |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="example"> |
|
|
|
|
|
<p>A simple calculator could use <code>output</code> for its |
|
|
display of calculated results:</p> |
|
|
|
|
|
<pre><form onsubmit="return false"> |
|
|
<input name=a type=number step=any> + |
|
|
<input name=b type=number step=any> = |
|
|
<output onforminput="value = a.value + b.value"></output> |
|
|
</form></pre> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<h4>Association of controls and forms</h4> |