Home » How-To's

Creating window styled boxes using CSS

9 June 2008 6 views No Comment

While I was designing my home page Veerasundar.com, I came up with this style definition which can create window styled boxes in a HTML page. I am sharing the style definitions and HTML snippet here, so that if anybody else wants to create the same, they could re-use the same. Off course, there are multiple advanced scripts are available, but below is very basic one, which if you know little HTML and CSS, you can extend it for your own need.

CSS Style definitions:

#Box
{
margin:5px;
text-align:left;
}
#Box #BoxTitle
{
background-color:#EEE;
border:1px solid #DDD;
font-weight:bold;

padding:3px;
font-size:14px;
}

#Box #BoxContent
{
background-color:#FFF;
padding:10px;
border:1px solid #DDD;
border-top-style:none;
line-height:1.5;
font-size:13px;
}


HTML Code:

<div id=”Box”>
<div id=”BoxTitle”>
Here goes the Window Title!
</div>
<div id=”BoxContent”>
Here goes the content for your Windowed HTML box.
</div>
</div>

If you want to see examples of the CSS boxes, then take a look at Veerasundar.com (As of June, I was having a template with Boxes in it. Hope I will not change this template in future! :D )

Tags: , ,

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...

Leave your response!

Add your comment below, or trackback from your own site. You can also subscribe to these comments via RSS.

Be nice. Keep it clean. Stay on topic. No spam.

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

This is a Gravatar-enabled weblog. To get your own globally-recognized-avatar, please register at Gravatar.