Wrapping text with css
Question
I have the following html:
<label class="description">Label Text</label><input type="password" />
And the css styles are:
fieldset span.formrow label.description {
width: 150px;
display: -moz-inline-box;
display: inline-block;
}
My problem is that in Firefox 2 if the text goes over the 150px limit, then the line does not break. Instead the text is displayed behind the input text field.
Any chance that the behavior can be altered?
Solution
fieldset span.formrow label.description {
width: 150px;
float:left;
clear:left;
}
Try this!
Andrew
OTHER TIPS
Try:
fieldset span.formrow label.description { width: 150px; display: block; float: left; }
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow