NEWS DAILY
..... INDO BLOG'S

Sunday, October 16, 2011

Set The Page Margins


Blogs page will look nicer if the margin is greater. You can set the margins to the left margin and right margin, see examples CSS code  bellow:


<style type="text/css">
body {margin-left: 5%;margin-right: 5%;}
</style>

The example above shows the margin to 5% of the width of the window and the margins will
change the scale of the browser window size.

  • Set the left and right indents
That looks slightly different titles, you can create a margin for the body. follow's example code bellow:
<style type="text/css">
body {margin-left: 5%; margin-right: 5%;}
h1 {margin-left: -6%}
h2,h3,h4,h5,h6 {margin-left: -3%;}
</style>

The example has three functions: to set the body margin, head h1 and titles your blogs.

No comments: