Text goes goes into separate lines when using a percentage padding
Posted
by
Haxed
on Stack Overflow
See other posts from Stack Overflow
or by Haxed
Published on 2011-02-18T06:32:59Z
Indexed on
2011/02/18
7:25 UTC
Read the original article
Hit count: 281
Hi, I have a small problem in html forms. When I give the following css,
.row .section-1 label {/* Formatting all section-1 labels */
padding: 0 5px 0 10px;
margin: 3px 0 0 0;
display:block;
}
This is the output that I get :
However when I edit the css to put padding in the form of a percentage:
.row .section-1 label {/* Formatting all section-1 labels */
padding: 0 40% 0 80%;
margin: 3px 0 0 0;
display: block;
}
This is the output I get :
I want to use percentages, however I want the look in the first image. Any ideas??
Thanks
© Stack Overflow or respective owner