mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-07 14:16:47 +02:00
adding code snippets to form examples
This commit is contained in:
@@ -852,9 +852,9 @@ For example, <code>section</code> should be wrapped as inline.
|
||||
|
||||
|
||||
<h2>Example forms <small>using just form controls, no extra markup</small></h2>
|
||||
<h3>Basic form</h3>
|
||||
<div class="row">
|
||||
<div class="span3">
|
||||
<h3>Basic form</h3>
|
||||
<p>With v2.0, we have lighter and smarter defaults for form styles. No extra markup, just form controls.</p>
|
||||
</div>
|
||||
<div class="span9">
|
||||
@@ -866,11 +866,21 @@ For example, <code>section</code> should be wrapped as inline.
|
||||
</label>
|
||||
<button type="submit" class="btn">Submit</button>
|
||||
</form>
|
||||
<pre class="prettyprint linenums">
|
||||
<form class="well">
|
||||
<label>Label name</label>
|
||||
<input type="text" class="span3" placeholder="Type something…"> <span class="help-inline">Associated help text!</span>
|
||||
<label class="checkbox">
|
||||
<input type="checkbox"> Check me out
|
||||
</label>
|
||||
<button type="submit" class="btn">Submit</button>
|
||||
</form>
|
||||
</pre>
|
||||
</div>
|
||||
</div> <!-- /row -->
|
||||
<h3>Search form</h3>
|
||||
<div class="row">
|
||||
<div class="span3">
|
||||
<h3>Search form</h3>
|
||||
<p>Reflecting default WebKit styles, just add <code>.form-search</code> for extra rounded search fields.</p>
|
||||
</div>
|
||||
<div class="span9">
|
||||
@@ -878,11 +888,17 @@ For example, <code>section</code> should be wrapped as inline.
|
||||
<input type="text" class="input-medium search-query">
|
||||
<button type="submit" class="btn">Search</button>
|
||||
</form>
|
||||
<pre class="prettyprint linenums">
|
||||
<form class="well form-search">
|
||||
<input type="text" class="input-medium search-query">
|
||||
<button type="submit" class="btn">Search</button>
|
||||
</form>
|
||||
</pre>
|
||||
</div>
|
||||
</div> <!-- /row -->
|
||||
<h3>Inline form</h3>
|
||||
<div class="row">
|
||||
<div class="span3">
|
||||
<h3>Inline form</h3>
|
||||
<p>Inputs are block level to start. For <code>.form-inline</code> and <code>.form-horizontal</code>, we use inline-block.</p>
|
||||
</div>
|
||||
<div class="span9">
|
||||
@@ -891,6 +907,13 @@ For example, <code>section</code> should be wrapped as inline.
|
||||
<input type="password" class="input-small" placeholder="Password">
|
||||
<button type="submit" class="btn">Go</button>
|
||||
</form>
|
||||
<pre class="prettyprint linenums">
|
||||
<form class="well form-inline">
|
||||
<input type="text" class="input-small" placeholder="Email">
|
||||
<input type="password" class="input-small" placeholder="Password">
|
||||
<button type="submit" class="btn">Go</button>
|
||||
</form>
|
||||
</pre>
|
||||
</div>
|
||||
</div><!-- /row -->
|
||||
|
||||
|
Reference in New Issue
Block a user