Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Sebastian Wilson
15,710 PointsText next to image
I have an image next to it I would like the text to be vertically aligned middle please and when the screen gets small for it to be below it the image never gets smaller.
Currently I am doing this
<p><img style="width: 156px; height: 157px;" src="/250.png" alt="250" data-id="1528">Today we will be talking about young people will have 250 pupils in the following year.</p>
But issues is after around 7 words the words start going below the image so I have 7 in middle as desired and the rest below image.
I can use bootstrap if that's
Thanks a lot
1 Answer
codegay
14,410 Pointsthis should work
<div>
<p style="float: left;"><img src="" height="200px" width="200px" border="1px"></p>
<p>Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text</p>
</div>