PDA

View Full Version : 2 elements in 1 container inline with similar containers



eljhongo
18 Nov 2009, 09:24 PM
This seems simple in my head but I have been going nuts all day now. I have knowledge of CSS/HTML but apparently not enough. Lol... What I am doing is dynamically loading some images into a gallery. The images display inline and are scrolled left and right. All is well. Now I need to add text below each image, the problem then becomes that the images either stack up or the text display inline with the images. I have put the image and text within a container but that still doesn't work. Please help. Thank you for any and all help.

kozzleto
20 Nov 2009, 06:55 AM
Hi.. i don't know, i'm too lazy to trying it, but just a try...


div#container { width:???; float: left;}
div#container p { float:left; text-align:left;} <- and some font styles..

also try with or without -> div#container img { clear: both; display:block;}
or try putting <br /> after the <img>.. and before the <p>