• Das Erstellen neuer Accounts wurde ausgesetzt. Bei berechtigtem Interesse bitte Kontaktaufnahme über die üblichen Wege. Beste Grüße der Admin

CSS Space oberhalb Text

SportGoofy

New member
Hi!!!!

Habe mir einen Text mit CSS formatiert.
Jetzt besitzt dieser Text wohl am oberen Rand noch reichlich Freiraum (den ich aber weghaben will). Mit margin-top: 1px geht es nicht. Weiß jemand Rat???
 
Code:
<html>
<Head>
<Title>
Dies ist meine TestSite
</Title>
</Head>
<style type="text/css">
body {background-color: cccc99}
</style>
<body>
<P style="color: black; margin-top: 1px; font-size: 65px; font-weight: bold; 
float: left">Bert</p>
<P style="color: blue; margin-top: 5px; margin-bottom: 1px; font-size: 30px">Text</p>
</body>
</html>

Here it comes
Also der rechte Text soll etwas niedriger anfangen als der linke.
Aber der linke soll eben oben anfangen.

Hoffe man versteht was ich meine :rolleyes:
 
Zuletzt bearbeitet:
HTML:
<html>
<Head>
<Title>
Dies ist meine TestSite
</Title>
</Head>
<style type="text/css">
body {background-color: cccc99}
</style>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<P style="color: black; margin-top: -5px; font-size: 65px; font-weight: bold; 
float: left">Bert</p>
<P style="color: blue; margin-top: -5px; margin-bottom: 0px; font-size: 30px">Text</p>
</body>
</html>

So ist kein Rand mehr da. Soll das so sein?
 
<P style="color: black; margin-top: -20px; font-size: 65px; font-weight: bold;
float: left">Bert</p>

Negativer Wert.
Ist aber nicht elegant, wie ich finde...
 
Zurück
Oben