ASPForums.Net RSS Feedhttp://www.aspforums.net/Handlers/RSS.ashxLatest additions to the content that appears on ASPForums.Net(c) 2019 www.aspforums.com. All rights reserved.Vertically align Label and Input in Bootstrap using CSS<p>Hi <a class="username" rel="jmontano"> jmontano</a>,</p> <p>For Label controls assign&nbsp;CssClass <strong>control-label col-md-2</strong> instead of <strong>control-label col-md-4</strong>.</p> <p><strong><span style="text-decoration: underline;">HTML</span></strong></p> <pre class="brush: html">&lt;div class=&#34;row&#34;&gt; &lt;div class=&#34;col-md-6&#34;&gt; &lt;div class=&#34;form-group&#34;&gt; &lt;asp:Label ID=&#34;Fecha&#34; runat=&#34;server&#34; CssClass=&#34;control-label col-md-2&#34; Text=&#34;Fecha del:&#34;&gt;&lt;/asp:Label&gt; &lt;div class=&#34;input-group&#34;&gt; &lt;div class=&#34;input-group-addon&#34;&gt; &lt;i class=&#34;fa fa-calendar&#34;&gt;&lt;/i&gt; &lt;/div&gt; &lt;asp:TextBox class=&#34;form-control&#34; ID=&#34;date&#34; name=&#34;date&#34; runat=&#34;server&#34; required=&#34; &#34;&gt;&lt;/asp:TextBox&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class=&#34;form-group&#34;&gt; &lt;asp:Label ID=&#34;Apellido&#34; runat=&#34;server&#34; CssClass=&#34;control-label col-md-2&#34; Text=&#34;Seguro:&#34;&gt;&lt;/asp:Label&gt; &lt;div class=&#34;col-md-6&#34;&gt; &lt;asp:DropDownList ID=&#34;ddlSeguro&#34; runat=&#34;server&#34; class=&#34;form-control selectpicker validate[required]&#34; data-show-subtext=&#34;true&#34; data-live-search=&#34;true&#34;&gt; &lt;/asp:DropDownList&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class=&#34;col-md-6&#34;&gt; &lt;div class=&#34;form-group&#34;&gt; &lt;asp:Label ID=&#34;Label1&#34; runat=&#34;server&#34; CssClass=&#34;control-label col-md-2&#34; Text=&#34;Fecha al:&#34;&gt;&lt;/asp:Label&gt; &lt;div class=&#34;input-group&#34;&gt; &lt;div class=&#34;input-group-addon&#34;&gt; &lt;i class=&#34;fa fa-calendar&#34;&gt;&lt;/i&gt; &lt;/div&gt; &lt;asp:TextBox class=&#34;form-control&#34; ID=&#34;TextBox1&#34; name=&#34;date&#34; runat=&#34;server&#34; required=&#34; &#34;&gt;&lt;/asp:TextBox&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class=&#34;form-group&#34;&gt; &lt;asp:Label ID=&#34;Label2&#34; runat=&#34;server&#34; CssClass=&#34;control-label col-md-2&#34; Text=&#34;Marca:&#34;&gt;&lt;/asp:Label&gt; &lt;div class=&#34;col-md-6&#34;&gt; &lt;asp:DropDownList ID=&#34;ddlMarca&#34; runat=&#34;server&#34; CssClass=&#34;form-control selectpicker validate[required]&#34; data-show-subtext=&#34;true&#34; data-live-search=&#34;true&#34; Style=&#34;width: 300px&#34;&gt; &lt;/asp:DropDownList&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt;</pre> <p>&nbsp;</p>https://www.aspforums.net:443/Threads/103655/Vertically-align-Label-and-Input-in-Bootstrap-using-CSS/https://www.aspforums.net:443/Threads/103655/Vertically-align-Label-and-Input-in-Bootstrap-using-CSS/Fri, 13 Apr 2018 00:37:49 GMTVertically align Label and Input in Bootstrap using CSS<p>Hi <a class="username" rel="jmontano"> jmontano</a>,</p> <p>Add the below css.</p> <pre class="brush: css">&lt;style type=&#34;text/css&#34;&gt; .col-md-2 { width: auto; } &lt;/style&gt;</pre> <p>If it will not solve your issue you need to contact with a designer for changes in your design or need to read bootstrap to design your page.</p> <p>&nbsp;</p> <p>&nbsp;</p>https://www.aspforums.net:443/Threads/103655/Vertically-align-Label-and-Input-in-Bootstrap-using-CSS/https://www.aspforums.net:443/Threads/103655/Vertically-align-Label-and-Input-in-Bootstrap-using-CSS/Tue, 17 Apr 2018 01:19:17 GMT