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

bild unten links positionieren

Schneider

New member
ich habe mal ne Frage und habe mich schon dusselig gesucht ich habe einen div Container der hat eine fixe größe: width: 13px; height: 135px; mit einem Rahmen: 1px solid black
jetzt hab ich ein Bild das ist 15 x 15px dieses will ich das es immer unten links im Container positioniert ist das problem ist das ich über diesem Bil noch ein anderes Bild kommt, welches aber keine fixe Größe hat!

weiß jemand wie ich es einfach unten links positionieren kann mit bottom:0px gehts nicht und ich bin wirklich verzweifelt

wäre gut wenn man es mit CSS lösen könnte
thx für die Hilfe
 
Hi!

Bottom geht durchaus. Position ist wichtig:

<div style="position:absolute;left:100px;height:135px;width:135px;border:1px solid black">
<img src="1.gif" alt="" border="0" style="position:absolute;left:0;bottom:0;height:13px;width:13px">
</div>

Ahoi - Pit
 
danke erstmal für den Tip jetzt habe ich leider was vergessen zu erwähnen und zwar diesen div sollte es mehrmals geben (float:left) aber dann funzt das mit dem position:absolute nicht und das bild ist auch nicht ganz bündig ??? es hat ca. 1-2px abstand
 
Hi!

Spiel mal mit sowas 'rum:
PHP:
<div style="position:relative;top:100px;left:50px;">
<div style="position:relative;height:135px;width:135px;border:1px solid black;float:left">
<img src="1.gif" alt="" border=0 style="position:absolute;bottom:0 !important;bottom:-1px;height:13px;width:13px">
</div>
<div style="position:relative;height:135px;width:135px;border:1px solid black;float:left">
<img src="1.gif" alt="" border=0 style="position:absolute;bottom:0 !important;bottom:-1px;height:13px;width:13px">
</div>
<div style="position:relative;height:135px;width:135px;border:1px solid black;float:left">
<img src="1.gif" alt="" border=0 style="position:absolute;bottom:0 !important;bottom:-1px;height:13px;width:13px">
</div>
</div>
Ahoi - Pit
 
1000 dank funktioniert super :D

jetzt hab ich noch ne Frage weiß allerdings ob es überhaupt möglich ist und zwar
jetzt hab ich den div wo das bild unten links jetzt will ich das über dem das bild immer zentriert ist sowol vertikal und horizontal ich habs schon mit vertical-align versucht allerdings ohne erfolg

so noch ne Frage am Rande (ich will ja auch was lernen) was ist das für ein tag (!important) ich hab gar nicht gewusst das es so was gibt
 
Zuletzt bearbeitet:
Zurück
Oben