Andreas De Rudder Posted February 10, 2016 Share Posted February 10, 2016 Hallo, I want to have on my website 2 images on top of each other, each has a little bit of text on the right side. Each picture has STYLE="float: left;. I have put <p> in front of the picture and </p> after the text. Done that 2 times. But the second pictures appears at the right side of the first picture, under the text next to the first picture. Why is that? What can I do to get the pictures under each other? My website: http://msngent.be/adresses.html Andreas 1 Link to comment Share on other sites More sharing options...
dsonesuk Posted February 10, 2016 Share Posted February 10, 2016 Float on image will cause outer parent paragraph to collapse to text content ignoring the area of image, it will also seep its effect to sibling parent paragraphs, to correct this, apply overflow: hidden; to parent paragraphs of floated images. Link to comment Share on other sites More sharing options...
Andreas De Rudder Posted February 10, 2016 Author Share Posted February 10, 2016 I have tried this by writing <p><overflow: hidden> in the first paragraph in front of the image, but then the whole paragraph totally disappears... Have I done it wrong? Link to comment Share on other sites More sharing options...
dsonesuk Posted February 10, 2016 Share Posted February 10, 2016 Yep! should be <p style="overflow: hidden;"><img width="200" style="float: left; margin-right: 25px; margin-bottom: 25px" title="St Stefanuschurch" alt="picture St Stefanuschurch" src="images/ststefanuskerk.jpg"> The Santo Niño Mass takes place in the St Stefanus Church, Sint‑Margrietstraat 11, 9000 Gent. Back in the church you’ll find the entrance to the Holy Rita Chapel. On the picture you see the church on the right and the presbytery on the left side.</p> <p style="overflow: hidden;"><img width="200" style="float: left; margin-right: 25px; margin-bottom: 25px" title="Augustinian Monastery Augustijnenkaai" alt="picture Augustinian Monastery Augustijnenkaai" src="images/augustijnenkaai.jpg"> Meeting with Jesus takes place in the Augustinian Monastery, Augustijnenkaai, 9000 Gent. You’ll find there the monastery’s rear entrance and park place (Take care: only for private use, not for visitors!), on the park place enter the first door on the left.</p> Link to comment Share on other sites More sharing options...
Andreas De Rudder Posted February 10, 2016 Author Share Posted February 10, 2016 Thank you very much! It works perfect now! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now