значения свойства:
values of the property:
.
left
, .
right
both
{
height
:
150px
;
width
400px
border
1px
solid
#808080
}
.one, .two {
50px
100px
background-color
#3BA9DE
margin
5px
.one {
float
.two {
.text {
text-align
justify
.clear-
clear
.left, .right, .both { height: 150px; width: 400px; border: 1px solid #808080; } .one, .two { height: 50px; width: 100px; background-color: #3BA9DE; margin: 5px; } .one { float: left; } .two { float: right; } .text { text-align: justify; } .clear-left { clear: left; }
<!DOCTYPE html>
<
html
>
head
meta
charset
=
"utf-8"
/>
title
>New Page</
link
href
"css/style.css"
rel
"stylesheet"
script
type
"text/javascript"
src
"https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"
></
</
body
div
class
"left"
"one"
p
"clear-left text"
I was dreaming about Hawaii. I was dreaming about my holiday. In
my dream, I was on the beach in Hawaii. The hot sun was shining on
my face. The sound of the sea was all around me.
br
"right"
"two"
id
"p1"
"text"
"both"
"clear-both text"
/*JavaScript*/
document.getElementById("p1").style.clear = "right";
/*jQuery*/
$(document).ready(function () {
$(".clear-both").css({ "clear": "both" });
});