Pure CSS table using UL and LI

this is the nice way for achieving the 100% tableless design.
here, by the use of UL and LI, we can make the Pure CSS Table.

<html>
<head>
<title>pure css table</title>
<style>
.table{background:None;}
.table ul{float:left;margin:0px;padding:0px;}
.table ul li{list-style:none;padding:4px 9px;}
.table ul li.title{font-weight:bold;background:#333;color:#fff;}
.table ul li.even{background:#fff;}
.table ul li.odd{background:#FFFFE6;}
</style>
</head>
<body>
<div class="table">
<ul>
<li class="titile">country</li>
<li class="odd">India</li>
<li class="even">US</li>
<li class="odd">England</li>
<li class="even">Japan</li>
</ul>
<ul>
<li class="titile">city</li>
<li class="odd">Mumbai</li>
<li class="evev">Washington</li>
<li class="odd">London</li>
<li class="even">Tokyo</li>
</ul>
</div>
</body>
</html>

Hope this post will be helpful.
Please share / recommend if you like.

Thanks,
Nikhil Ughade
UI Designer
Mumbai [INDIA]

Advertisements

Make your DIV (division) scrollable using css only & its Use

Sometimes there is limitation on width and height of page or element , then we can use this script/code to overcome.
you can scroll it only horizontle, only vertical or both direction.
The property is “OVERFLOW” which can be used as :
for only vertical :

overflow-y: scroll;
overflow-x: hidden;

for only horizontal:

overflow-y: hidden;
overflow-x: scroll;

for both vertical & horizontal:

overflow-y: scroll;
overflow-x: scroll;

Read more of this post

%d bloggers like this: