Skip to main content

Good Css for HTML Table

<style type="text/css" >



/* Table 3 Style */
#tbl{
    font-family:Arial;
    font-size: 12px;
    font-style: normal;
    font-weight: normal;
    text-transform: uppercase;
    letter-spacing: -1px;
    line-height: 1.7em;
    text-align:center;
    border-collapse:collapse;
}
#tbl thead th{
    padding:6px 10px;
    text-transform:uppercase;
    color:#444;
    font-weight:bold;
    text-shadow:1px 1px 1px #fff;
    border-bottom:5px solid #444;
}
#tbl thead th:empty{
    background:transparent;
    border:none;
}
#tbl thead :nth-child(2),
#tbl tfoot :nth-child(2){
    background-color: #7FD2FF;
}
#tbl tfoot :nth-child(2){
    -moz-border-radius:0px 0px 0px 5px;
    -webkit-border-bottom-left-radius:5px;
    border-bottom-left-radius:5px;
}
#tbl thead :nth-child(2){
    -moz-border-radius:5px 0px 0px 0px;
    -webkit-border-top-left-radius:5px;
    border-top-left-radius:5px;
}
#tbl thead :nth-child(3),
#tbl tfoot :nth-child(3){
    background-color: #45A8DF;
}
#tbl thead :nth-child(4),
#tbl tfoot :nth-child(4){
    background-color: #2388BF;
}
#tbl thead :nth-child(5),
#tbl tfoot :nth-child(5){
    background-color: #096A9F;
}
#tbl thead :nth-child(5){
    -moz-border-radius:0px 5px 0px 0px;
    -webkit-border-top-right-radius:5px;
    border-top-right-radius:5px;
}
#tbl tfoot :nth-child(5){
    -moz-border-radius:0px 0px 5px 0px;
    -webkit-border-bottom-right-radius:5px;
    border-bottom-right-radius:5px;
}
#tbl tfoot td{
    font-size:14px;
    font-weight:bold;
    padding:8px 0px;
    text-shadow:1px 1px 1px #fff;
}
#tbl tbody td{
    padding:8px;
}
#tbl tbody tr:nth-child(4) td{
    font-size:14px;
    font-weight:bold;
}
#tbl tbody td:nth-child(even){
    background-color:#444;
    color:#444;
    border-bottom:1px solid #444;
    background:-webkit-gradient(
        linear,
        left bottom,
        left top,
        color-stop(0.39, rgb(189,189,189)),
        color-stop(0.7, rgb(224,224,224))
        );
    background:-moz-linear-gradient(
        center bottom,
        rgb(189,189,189) 39%,
        rgb(224,224,224) 70%
        );
    text-shadow:1px 1px 1px #fff;
}
#tbl tbody td:nth-child(odd){
    background-color:#555;
    color:#f0f0f0;
    border-bottom:1px solid #444;
    background:-webkit-gradient(
        linear,
        left bottom,
        left top,
        color-stop(0.39, rgb(85,85,85)),
        color-stop(0.7, rgb(105,105,105))
        );
    background:-moz-linear-gradient(
        center bottom,
        rgb(85,85,85) 39%,
        rgb(105,105,105) 70%
        );
    text-shadow:1px 1px 1px #000;
}
#tbl tbody td:nth-last-child(1){
    border-right:1px solid #222;
}
#tbl tbody th{
    color:#696969;
    text-align:right;
    padding:0px 8px;
    border-right:1px solid #aaa;
}
img {

   display: block;
  -moz-box-sizing: border-box;

  background: url("images/check0.png");
  background-repeat:no-repeat;
  width: 70px; /* Width of new image */
  height: 50px; /* Height of new image */
  padding-left: 180px; /* Equal to width of new image */
   

}


</style>

Comments

  1. Amazing blog and very interesting stuff you got here! I definitely learned a lot from reading through some of your earlier posts as well and decided to drop a comment on this one!

    ReplyDelete

Post a Comment