ich will eine Überschrift die links daneben ein Icon (Bild 50x50) hat. Die Überschrift ist unterstrichen. Nun soll das Bild genau über der Unterstreichung sein, also 2 px über der linie oder so. Ich bekomme das aber irgenwie nicht hin. jemand nen tipp? hier mein html code:
- Code: Alles auswählen
[...]
<img class="headlineIcon" src="./files/icon.jpg"/><h2>Testüberschrift</h2>
[...]
und der dazugehörige CSS Style:
- Code: Alles auswählen
img.headlineIcon{
float:left;
margin-top: 5px;
margin-bottom: 5px;
padding-right: 5px;
padding-left: 5px;
width: 50px;
height: 50px;
}
h2 {
font-size: larger;
font-weight: bold;
margin-bottom:5px;
border-bottom:1px solid #D1d1d1;
text-align:left;
}
jemand einen tip? danke.
mfg ghostdog
