7
Contributors
6
Replies
7
Views
9 Years
Discussion Span
Last Post by Arkinder
0

Hi sreein,

This is the way I understand it, If you don't want to use relative positioning. Float would be your next bet. I use it mainly for layouts. But people do use it for images as well.

Here a nice little article on it, that explains it in a lot more depth and detail I ever could.

Click here

All the best.

0

Float tells the browser whether to make the text flow to the left or the right of an object.

i think that's the reverse of float. float makes elements "float" in the surrounding elements--to the left or right of those elements. the other elements (like text) just wrap around the floated element (like in word when you set the text wrapping around something).

you need to watch out though: floated elements take up no vertical space, you need to plan for that, usually by using the clear tag (which stops elements from floating to the left/right/both sides of an element.

also, using float is way easier than relative positioning. the only thing you need to watch out for is floated elements not taking up space.

0

It is called a universal rule in CSS. Let's say you have,

* {
    padding: 0;
    margin: 0;
}

Now every HTML element on the page will have a padding and margin of 0, and is often used to reset the default padding and margin created by the browser. This can be used with other CSS stylings too.

Regards, Arkinder

Edited by Arkinder: n/a

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.