阅读背景:

浮动块级元素:是否需要设置宽度,如果是,如何?

来源:互联网 

Say I have textboxes, dropdownlists and submit buttons. They are all inline-elements. Which means that "officially" margin, padding, width and height properties should be ignored (in practice not really). If I were to go the right way to set the height to a button I would write something like display:block and then define the height. But there are considerations that a block level element would expand itself unexpectedly so I'd better set its width to some fixed value. The problem is that I don't know its width since it can be dynamically defined upon the text of the button.Say I have textboxes, dropdownlists and submit




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: