Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Top Alignment in Bootstrap Form

Posted on 2016-09-03
6
Medium Priority
?
94 Views
Last Modified: 2016-09-03
How can I get the labels and other form controls to align at the top of the form on this page?
0
Comment
Question by:Bob Schneider
  • 4
  • 2
6 Comments
 
LVL 60

Accepted Solution

by:
Julian Hansen earned 2000 total points
ID: 41783027
Try adding this style to your custom styles
.form-inline .form-control {
  vertical-align: top;
}

Open in new window

0
 

Author Comment

by:Bob Schneider
ID: 41783031
Perfect.  Thank you!
0
 
LVL 60

Expert Comment

by:Julian Hansen
ID: 41783032
You are welcome.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 60

Expert Comment

by:Julian Hansen
ID: 41783034
Just a note - that style will affect all your forms. You might want to restrict it only to the form at the top of the page. Give the form a class (say 'topform') and then prefix the above styles with that class

.topform .form-inline .form-control {
  vertical-align: top;
}

Open in new window

0
 

Author Comment

by:Bob Schneider
ID: 41783039
Thanks.  This particular page will  only have one form but I appreciate the heads up.
0
 
LVL 60

Expert Comment

by:Julian Hansen
ID: 41783043
No problem - it is good practice anyway, sites change and you forget things - can cause unnecessary loss of time tracking down side effects.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer…
Introduction If you're like most people, you have occasionally made a typographical error when you're entering information into an online form.  And to your consternation, the browser remembers the error, and offers to autocomplete your future entr…
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
In this Micro Tutorial viewers will learn how to create a CSS image sprite (In a later tutorial, viewers will learn how to use CSS and HTML to create a navigation menu using this sprite) Open a new Photoshop document with a width of (Icon width)x(N…
Suggested Courses

886 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question