zoukankan      html  css  js  c++  java
  • CSS Image Rollovers翻转效果Image Sprites图片精灵

    代码
     1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
     2 <html xmlns="http://www.w3.org/1999/xhtml">
     3 
     4 <head>
     5 <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
     6 <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
     7 <title>CSS Image Rollovers,Image Sprites </title>
     8 <meta name="Author" content="涂聚文" />
     9 <meta name="Keywords" content= "自定义字体 缔友计算机信息技术有限公司 捷为工作室 www.dupcit.com,Image Sprites ,Image Rollovers" />
    10 <meta name="Description" content="自定义字体 缔友计算机信息技术有限公司 捷为工作室,Image Rollovers,Image Sprites" />
    11 <link rel="shortcut icon" href="http://www.dupcit.com/favicon.ico" type="image/x-icon" />
    12 <link rel="icon" href="http://www.dupcit.com/favicon.ico" type="image/ico" />
    13 
    14 <style type="text/css">
    15 
    16     .rollover a {
    17         display:block;
    18         width: 90px;
    19         padding:10px 10px 10px 7px;
    20         font: bold 13px sans-serif;;
    21         color:#333;
    22         background: url("rollover-image.gif") 0 0 no-repeat;
    23         text-decoration: none;
    24         }
    25     .rollover a:hover {    
    26         background-position: 0 -35px;
    27         color: #049;
    28         }
    29     .rollover a:active {
    30         background-position: 0 -70px;
    31         color:#fff;
    32         }
    33     #navlist{position:relative;}
    34 #navlist li{margin:0;padding:0;list-style:none;position:absolute;top:0;}
    35 #navlist li, #navlist a{height:44px;display:block;}
    36 
    37 #home{left:0px;width:46px;}
    38 #home{background:url('img_navsprites.gif') 0 0;}
    39 
    40 #prev{left:63px;width:43px;}
    41 #prev{background:url('img_navsprites.gif') -47px 0;}
    42 
    43 #next{left:129px;width:43px;}
    44 #next{background:url('img_navsprites.gif') -91px 0;} 
    45 
    46 </style>
    47 
    48 </head>
    49 <body><h2>CSS Rollover Example</h2>
    50 <p><href="pure-css-image-rollovers"><< Back</a></p>
    51 
    52 
    53 <div class="rollover">
    54     <href="#">Item 1</a>
    55     <href="#">Item 2</a>
    56     <href="#">Item 3</a>
    57     <href="#">Tutorio</a>
    58 </div>
    59 
    60 <p>View the source to see how this was done, visit <href="ure-css-image-rollovers">The Pure Css Image rollover tutorial</a>
    61  for an explanation</p>
    62 
    63 
    64 <ul id="navlist">
    65   <li id="home"><href="default.asp"></a></li>
    66   <li id="prev"><href="css_intro.asp"></a></li>
    67   <li id="next"><href="css_syntax.asp"></a></li>
    68 </ul>
    69 
    70 
    71 </body>
    72 </html>
    73 
  • 相关阅读:
    idea
    Docker
    建张表
    MySQL 时间字段默认值
    获取唯一字符串
    Java避免空指针
    Android自定义控件
    Android 中textview显示富文本信息
    apktool反编译详细使用教程
    【android动态布局】之【ListView动态加载数据模板(使用xml布局)】
  • 原文地址:https://www.cnblogs.com/geovindu/p/1884375.html
Copyright © 2011-2022 走看看