In chapter you will learn about setting a margin. You can move an object or div by setting the
the margin. you can set a margin in many
ways. Margin 0, 0 ,0 ,0 each parameter can be set as top, right,
bottom, left. Or you can set it individually
as Margin-left , margin-right,
margin-bottom, margin- top.
<!DOCTYPE html>
<head>
<title>Margins</title>
<style>
#moveMe{
Width: 200px;
Height: 200px;
Background-color: red;
Margin-left: 200px;
}
</style>
</head>
<body>
<div id=”moveMe”></div>
</body>
</html>
0 comments: