Skip to content
Permalink
Browse files

[e] (0) examples for <select required>

Fixing http://www.w3.org/Bugs/Public/show_bug.cgi?id=12694

git-svn-id: http://svn.whatwg.org/webapps@6493 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Aug 17, 2011
1 parent 154e945 commit 110251beef8ba0157914a54683ec7cd51070daad
Showing with 102 additions and 0 deletions.
  1. +34 −0 complete.html
  2. +34 −0 index
  3. +34 −0 source
&lt;/select&gt;
&lt;/p&gt;</pre>

<p>When there is no default option, a placeholder can be used
instead:</p>

<pre>&lt;select name="unittype" <strong>required</strong>&gt;
<strong>&lt;option value=""&gt; Select unit type &amp;lt/option&gt;</strong>
&lt;option value="1"&gt; Miner &lt;/option&gt;
&lt;option value="2"&gt; Puffer &lt;/option&gt;
&lt;option value="3"&gt; Snipey &lt;/option&gt;
&lt;option value="4"&gt; Max &lt;/option&gt;
&lt;option value="5"&gt; Firebot &lt;/option&gt;
&lt;/select&gt;</pre>

</div>

<div class=example>

</div>

<div class=example>

<p>Sometimes, a user has to select one or more items. This example
shows such an interface.</p>

<pre>&lt;p&gt;Select the songs from that you would like on your Act II Mix Tape:&lt;/p&gt;
&lt;select multiple required name="act2"&gt;
&lt;option value="s1"&gt;It Sucks to Be Me (Reprise)
&lt;option value="s2"&gt;There is Life Outside Your Apartment
&lt;option value="s3"&gt;The More You Ruv Someone
&lt;option value="s4"&gt;Schadenfreude
&lt;option value="s5"&gt;I Wish I Could Go Back to College
&lt;option value="s6"&gt;The Money Song
&lt;option value="s7"&gt;School for Monsters
&lt;option value="s8"&gt;The Money Song (Reprise)
&lt;option value="s9"&gt;There's a Fine, Fine Line (Reprise)
&lt;option value="s10"&gt;What Do You Do With a B.A. in English? (Reprise)
&lt;option value="s11"&gt;For Now
&lt;/select&gt;</pre>

</div>



<h4 id=the-datalist-element><span class=secno>4.10.10 </span>The <dfn><code>datalist</code></dfn> element</h4>
34 index
&lt;/select&gt;
&lt;/p&gt;</pre>

<p>When there is no default option, a placeholder can be used
instead:</p>

<pre>&lt;select name="unittype" <strong>required</strong>&gt;
<strong>&lt;option value=""&gt; Select unit type &amp;lt/option&gt;</strong>
&lt;option value="1"&gt; Miner &lt;/option&gt;
&lt;option value="2"&gt; Puffer &lt;/option&gt;
&lt;option value="3"&gt; Snipey &lt;/option&gt;
&lt;option value="4"&gt; Max &lt;/option&gt;
&lt;option value="5"&gt; Firebot &lt;/option&gt;
&lt;/select&gt;</pre>

</div>

<div class=example>

</div>

<div class=example>

<p>Sometimes, a user has to select one or more items. This example
shows such an interface.</p>

<pre>&lt;p&gt;Select the songs from that you would like on your Act II Mix Tape:&lt;/p&gt;
&lt;select multiple required name="act2"&gt;
&lt;option value="s1"&gt;It Sucks to Be Me (Reprise)
&lt;option value="s2"&gt;There is Life Outside Your Apartment
&lt;option value="s3"&gt;The More You Ruv Someone
&lt;option value="s4"&gt;Schadenfreude
&lt;option value="s5"&gt;I Wish I Could Go Back to College
&lt;option value="s6"&gt;The Money Song
&lt;option value="s7"&gt;School for Monsters
&lt;option value="s8"&gt;The Money Song (Reprise)
&lt;option value="s9"&gt;There's a Fine, Fine Line (Reprise)
&lt;option value="s10"&gt;What Do You Do With a B.A. in English? (Reprise)
&lt;option value="s11"&gt;For Now
&lt;/select&gt;</pre>

</div>



<h4 id=the-datalist-element><span class=secno>4.10.10 </span>The <dfn><code>datalist</code></dfn> element</h4>
34 source
&lt;/select>
&lt;/p></pre>

<p>When there is no default option, a placeholder can be used
instead:</p>

<pre>&lt;select name="unittype" <strong>required</strong>>
<strong>&lt;option value=""> Select unit type &lt/option></strong>
&lt;option value="1"> Miner &lt;/option>
&lt;option value="2"> Puffer &lt;/option>
&lt;option value="3"> Snipey &lt;/option>
&lt;option value="4"> Max &lt;/option>
&lt;option value="5"> Firebot &lt;/option>
&lt;/select></pre>

</div>

<div class="example">

</div>

<div class="example">

<p>Sometimes, a user has to select one or more items. This example
shows such an interface.</p>

<pre>&lt;p>Select the songs from that you would like on your Act II Mix Tape:&lt;/p>
&lt;select multiple required name="act2">
&lt;option value="s1">It Sucks to Be Me (Reprise)
&lt;option value="s2">There is Life Outside Your Apartment
&lt;option value="s3">The More You Ruv Someone
&lt;option value="s4">Schadenfreude
&lt;option value="s5">I Wish I Could Go Back to College
&lt;option value="s6">The Money Song
&lt;option value="s7">School for Monsters
&lt;option value="s8">The Money Song (Reprise)
&lt;option value="s9">There's a Fine, Fine Line (Reprise)
&lt;option value="s10">What Do You Do With a B.A. in English? (Reprise)
&lt;option value="s11">For Now
&lt;/select></pre>

</div>



<h4>The <dfn><code>datalist</code></dfn> element</h4>

0 comments on commit 110251b

Please sign in to comment.
You can’t perform that action at this time.