How to force a checkbox and text on the same line?

前端 未结 6 438
长情又很酷
长情又很酷 2020-12-28 11:51

How can I force a checkbox and following text to appear on the same line? In the following HTML, I\'d only want the line to break between label and input, not between input

6条回答
  •  南笙
    南笙 (楼主)
    2020-12-28 12:28

    It wont break if you wrap each item in a div. Check out my fiddle with the link below. I made the width of the fieldset 125px and made each item 50px wide. You'll see the label and checkbox remain side by side on a new line and don't break.

    http://jsfiddle.net/t5dwp7pg/1/

提交回复
热议问题