michaellunsford Posted March 23, 2007 Share Posted March 23, 2007 <h1> has a default style of display block. The problem is, it's huge. It's got a whole line of whitespace above and below. But, on the flip side, display:inline has the right height, but the width stinks. Is there a way to display a heading as block width, but inline height? Link to comment https://forums.phpfreaks.com/topic/43972-solved-inline-too-small-block-too-big/ Share on other sites More sharing options...
AndyB Posted March 23, 2007 Share Posted March 23, 2007 h1 { margin-top:3px; margin-bottom:3px; } or whatever margins you want to use Link to comment https://forums.phpfreaks.com/topic/43972-solved-inline-too-small-block-too-big/#findComment-213531 Share on other sites More sharing options...
cmgmyr Posted March 23, 2007 Share Posted March 23, 2007 you can just about make any tag look the way you want it...perks of CSS Link to comment https://forums.phpfreaks.com/topic/43972-solved-inline-too-small-block-too-big/#findComment-213538 Share on other sites More sharing options...
michaellunsford Posted March 23, 2007 Author Share Posted March 23, 2007 <h1> has a default style of display block. The problem is, it's huge. It's got a whole line of whitespace above and below. But, on the flip side, display:inline has the right height, but the width stinks. Is there a way to display a heading as block width, but inline height? ahhh, it has built in margin. Nice. This is exactly what I was looking for. AndyB never misses. Thanks! Link to comment https://forums.phpfreaks.com/topic/43972-solved-inline-too-small-block-too-big/#findComment-213821 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.