Breaking News

css Load More



Wednesday, 10 July 2013

CSS; CSS Margin - Learn CSS for Free and Fun ......


With CSS we can set Margins at the

 top of the page
 bottom of the page
 right of the page
 left of the page

Tags:

margin-top: 5cm;
margin-right: 6cm;
margin-bottom: 7cm;
margin-left: 8cm;
margin: 5cm 6cm 7cm 8cm;

A margin is a space around an object. We can set margin in web pages using CSS. Using
separate properties within margin syntax we can define space all around the element.

Example:

<html>
<head>
<style type="text/css">
p.margin {margin: 2cm 4cm 3cm 4cm;}
</style>
</head>
<body>
<p>This is a paragraph with no specified margins</p>
<p class="margin">This is a paragraph with specified margins</p>
<p>This is a paragraph with no specified margins</p>
</body>
</html>
Share This
Blogger
Facebook
Disqus

comments powered by Disqus

No comments:

Post a Comment

Subscribe
Labels
Popular Posts

Subscribe Via Email

About Us

Advertisment

Like Us

© tryiblog All rights reserved | Designed By Seo Blogger Templates