What is CSS The Float?
With CSS float, an element can be pushed to the left or right,
allowing other elements to wrap around it.
How Elements Float
Elements are floated horizontally, this means that an element can only be floated left or right, not up or down.A floated element will move as far to the left or right as it can. Usually this means all the way to the left or right of the containing element.
The elements after the floating element will flow around it.
The elements before the floating element will not be affected.
If an image is floated to the right, a following text flows around it, to the left:
Floating Elements Next to Each Other
If you place several floating elements after each other, they will float next to each other if there is room.Here we have made an image gallery using the float property:
Turning off Float - Using Clear
Elements after the floating element will flow around it. To avoid this, use the clear property.The clear property specifies which sides of an element other floating elements are not allowed.
Add a text line into the image gallery, using the clear property:
More Examples for you....
An image with border and margins that floats to the right in a paragraphLet an image or photo float to the right in a paragraph. Add border and margins to the image.
An image with a caption that floats to the right
Let an image or photo with a caption float to the right.
Let the first letter of a paragraph float to the left
Let the first letter of a paragraphs float to the left and style the letters.
Creating a horizontal menu
Use float with a listed of hyperlinks to create a new a horizontal menu.
Creating a homepage without tables
Uses float to create a web homepage with a headers, footers, left contents and main contents.
All css and css3 for css tools and css3 tools with css code generator and css3 code generator. All css generator and css3 generator for css button gerator and css3 button generator, css gradient generator and css3 gradient generator, css menu maker and css menu maker, css button maker and css3 button maker other help css editor and css3 editor.
No comments:
Post a Comment