CSS for a Calendar-Like Date Stamp

May 23rd, 2008

The date stamp you see here on the page can be made with following code:

.post-date {
 background: url(images/date_icon_blue.jpg) no-repeat;
 float: left;
 height: 40px;
 line-height: 18px;
 margin: 0px 5px 0px 0px;
 text-align: center;
 width: 37px;
}

.post-day {
 color: #434B4D;
 font-size: 20px;
 margin: 0px 0px 1px 0px;
 padding: 0px;
 text-align: center;
 width: 37px;
}

.post-month {
 color: #FFFFFF;
 font-size: 10px;
 margin: 0px 0px 1px 0px;
 padding: 0px;
 text-align: center;
 width: 37px;
}
Background image used in the code:

One Response to “CSS for a Calendar-Like Date Stamp”

  1. Luke says:

    I like the way you write! Nice blog.

Please add your comment