Html noobs布局

Html noobs布局,html,Html,如何使这3个元素(范围、输入、输入)显示在同一行中?就像现在一样,跨度取左列和两行,两个输入取右列,一个在另一个之下 <div class="input-group"> <span class="input-group-addon" id="basic-addon1">www</span> <input type="text" class="form-control"

如何使这3个元素(范围、输入、输入)显示在同一行中?就像现在一样,跨度取左列和两行,两个输入取右列,一个在另一个之下

           <div class="input-group">
                <span class="input-group-addon" id="basic-addon1">www</span>
                <input type="text" class="form-control" placeholder="Url" ng-model="currentUrl"/>
                <input type="button" class="btn btn-primary" value="Go" ng-click="getUrl()" />
            </div>

万维网

只需添加以下css

span{
width:200px;
float:left;

}

input{
width:300px;
float:left;
}

假设您使用的是引导,您需要使用
.input group按钮


万维网

我无法重现您描述的问题:@Quentin如果您包括bootstrap,您可以
<div class="input-group">
  <span class="input-group-addon" id="basic-addon1">www</span>
  <input type="text" class="form-control" placeholder="Url" ng-model="currentUrl">

  <span class="input-group-btn">
    <input type="button" class="btn btn-primary" value="Go" ng-click="getUrl()">
  </span>
</div>