css實現滑鼠滑過改變文字(中文變英文)

來源:互聯網
上載者:User

滑鼠滑過改變文字的效果想必很多朋友都有遇到過吧,本文為大家介紹下css是如何?的,感興趣的朋友可以瞭解下

 

複製代碼代碼如下:


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>滑鼠經過變換文字</title>
<style>
#Menu {
width:500px;
margin:50px auto;
border:1px solid #CCC;
overflow:hidden;
}
#Menu ul {
margin:0;
padding:0;
list-style:none;
}
#Menu li {
width:100px;
height:22px;
line-height:22px;
float:left;
overflow:hidden;
text-align:center;
}
#Menu a {
width:100px;
float:left;
overflow:hidden;
}
#Menu span {
display:block;
margin-top:-22px;
}
#Menu a:hover {
padding-top:22px;
}
</style>
</head>
<body>
<ul id="Menu">
<li><a href="#"><span>HOME</span>首頁</a></li>
<li><a href="#"><span>NEWS</span>新聞</a></li>
<li><a href="#"><span>ABOUT</span>關於</a></li>
<li><a href="#"><span>CONTACT</span>聯絡</a></li>
<li><a href="#"><span>照片</span>PHOTO</a></li>
</ul>
</body>
</html>

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.