今天在网上浏览时看到用CSS来实现各国的国旗,真的很牛,拿过来给大家分享下,把下面的文件保存为.htm文件,预览下就能看到各国的国旗了。
*{
margin:0px;
padding:0px;
}
ul{
padding:0px;
margin:0px;
}
div{
width:160px;
height:85px;
}
#Germany ul li,#Paraguay ul li,#Netherlands ul li,#Argentina ul li{
height:28px;
text-align:center;
}
#Ecuador ul li.yellow{
height:38px;
}
#England ul li,#sweden ul li{
float:left;
background:white;
width:76px;
height:40px;
}
#sweden ul li{
background:blue;
}
#sweden .arrow{
width:50px;
}
#frence ul li,#italy ul li{
float:right;
width:53px;
height:85px;
}
#Ukraine ul li{
height:42px;
}
#Switzerland ul li{
float:left;
width:48px;
height:25px;
background:white;
}
#china ul li{
color:yellow;
float:left;
}
#china ul li.bigstart{
font-size:65px;
}
--------------------Germany
--------------------Ecuador
-------------------- England
-------------------- Sweden
-------------------- Netherlands
- ¤
-------------------- Argentina
-------------------- frence
-------------------- italy
-------------------- Ukraine
-------------------- Switzerland
- ★
- ★
- ★
- ★
- ★