Making Images Float

You can use the align attribute (with the left and right values only) to make images float along one side of your page, with text and other elements wrapping around the other.

To make images float:

1.
Type <img src="image.jpg" where image.jpg indicates the location of the image on the server.
2.
Either type align="left" to float the image on the left of the screen while the text flows to the right, or type align="right" to float the image on the right edge of the screen while the text flows on the left side of the image.
3.
Add other image attributes, as described in other parts of this chapter, if desired.
4.
Type the final />.
5.
Create the elements that should flow next to the image.
Figure 5.22. When you align an image ...

Get HTML, XHTML, & CSS, Sixth Edition: Visual QuickStart Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.