Solved

Vertical Alignment Form/Label

Posted on 2010-08-15
2
721 Views
Last Modified: 2012-05-10
Hello

I am relatively new to CSS and I am struggling to solve this simple problem.

In the attached example, there is a form on the left. I can't get the labels to be vertically aligned with the inputs. The labels are all a bit above the baseline of the text in the inputs (Chrome and IE8). (cf image attached "mismatch")

I am sure it must be simple to fix but I tried all sort of combinations of vertical-aligns on the different div/labels without success.

Thanks in advance
Charles

index.html
style.css
mismatch.png
0
Comment
Question by:cm2187
2 Comments
 
LVL 16

Accepted Solution

by:
HagayMandel earned 125 total points
ID: 33441652
Add to the label span css the following:
padding-top:1px;

This will do it
0
 

Author Closing Comment

by:cm2187
ID: 33441987
actually 3px did the trick!
Thanks!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

919 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now