Vincent Decaux Vincent Decaux - 4 months ago 13
CSS Question

Boostrap 3 input with addon and help block

Using Bootstrap CSS 3.3.1, I got a little problem with an input with an addon and a help block.

Just see the fiddle :

Tested on Firefox / Chrome. Is the markup wrong ? I tried "input-group" ... as class without success

Here is the markup :

<div class="form-group">
<label for="title" class="control-label col-md-3">Titre de la page</label>
<div class="col-md-9 input-group">
<div class="input-group-addon">
<input type="text" value="Value test" class="form-control input-xxlarge" id="title" name="title" size="46" />
<span class="help-block">Help Lorem Ipsum</span>

Ted Ted

Try it like this:

<div class="form-horizontal">
    <div class="form-group">
        <label for="title" class="control-label col-sm-3">Titre de la page</label>
        <div class="col-sm-9">
            <div class="input-group">
              <span class="input-group-addon">@</span>
                <input type="text" id="title" name="title"  class="form-control" />
            <p class="help-block">Example block-level help text here.</p>

See this updated fiddle

(stretch the preview pane to see the column support)