CSS实例讲解:地图提示(2)
作者:blank 来源:蓝色理想 发布时间:2007-05-11 17:04:00
标签:map,pop,css,hover
首先我们要显示5部分内容,内容结构相似,我们可以选用无序列表来显示介绍的图片和内容:
<ul>
<li><a id="map01" href="#map01"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111743602.jpg" alt="Post Office" />This is the Popsville community <strong>Post Office</strong>, your home of over-priced postage. Click map for more</a></li>
<li><a id="map02" href="#map02"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111743990.jpg" alt="Dew Drop Inn" />Home is where the beer is. And that means the <strong>Dew Drop Inn</strong>. Live music on the weekends. Click map for more</a></li>
<li><a id="map03" href="#map03"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744507.jpg" alt="River Beach" />Spend lazy summer afternoons at the beautiful <strong>River Beach</strong>. Hang out on the nude beach. Click map for more</a></li>
<li><a id="map04" href="#map04"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744638.jpg" alt="Woodland Traders" />Our local <strong>Woodland Traders</strong> is a veritable Mecca of consumer goods and hardware. Click map for more</a></li>
<li><a id="map05" href="#map05"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744924.jpg" alt="Wild Game Diner" />Country living means road kill, and the <strong>Wild Game Diner</strong> prepares it with special sauce. Click map for more</a></li>
</ul>
对于a中的内容我们进行隐藏,我们考虑增加span元素来实现,代码修改如下:
<ul>
<li><a id="map01" href="#map01"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111743602.jpg" alt="Post Office" />This is the Popsville community <strong>Post Office</strong>, your home of over-priced postage. Click map for more</span></a></li>
<li><a id="map02" href="#map02"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111743990.jpg" alt="Dew Drop Inn" />Home is where the beer is. And that means the <strong>Dew Drop Inn</strong>. Live music on the weekends. Click map for more</span></a></li>
<li><a id="map03" href="#map03"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744507.jpg" alt="River Beach" />Spend lazy summer afternoons at the beautiful <strong>River Beach</strong>. Hang out on the nude beach. Click map for more</span></a></li>
<li><a id="map04" href="#map04"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744638.jpg" alt="Woodland Traders" />Our local <strong>Woodland Traders</strong> is a veritable Mecca of consumer goods and hardware. Click map for more</span></a></li>
<li><a id="map05" href="#map05"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744924.jpg" alt="Wild Game Diner" />Country living means road kill, and the <strong>Wild Game Diner</strong> prepares it with special sauce. Click map for more</span></a></li>
</ul>
在显示的时候文字会跟着图片排版,为了方便我们对其中的描述文字进行样式调整而不影响图片的布局,我们单独给描述文字增加span元素,代码修改如下:
<ul>
<li><a id="map01" href="#map01"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111743602.jpg" alt="Post Office" /><span>This is the Popsville community <strong>Post Office</strong>, your home of over-priced postage. Click map for more</span></span></a></li>
<li><a id="map02" href="#map02"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111743990.jpg" alt="Dew Drop Inn" /><span>Home is where the beer is. And that means the <strong>Dew Drop Inn</strong>. Live music on the weekends. Click map for more</span></span></a></li>
<li><a id="map03" href="#map03"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744507.jpg" alt="River Beach" /><span>Spend lazy summer afternoons at the beautiful <strong>River Beach</strong>. Hang out on the nude beach. Click map for more</span></span></a></li>
<li><a id="map04" href="#map04"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744638.jpg" alt="Woodland Traders" /><span>Our local <strong>Woodland Traders</strong> is a veritable Mecca of consumer goods and hardware. Click map for more</span></span></a></li>
<li><a id="map05" href="#map05"><span class="offset"><img src="https://img.aspxhome.com/file/UploadPic/20075/20075111744924.jpg" alt="Wild Game Diner" /><span>Country living means road kill, and the <strong>Wild Game Diner</strong> prepares it with special sauce. Click map for more</span></span></a></li>
</ul>


猜你喜欢
- 本文实例讲述了JS实现简洁、全兼容的拖动层。分享给大家供大家参考。具体分析如下:这是一款最简洁的JS层拖动代码,全兼容ie、ff、opera
- MySQL Workbench 是一款专为 MySQL 设计的集成化桌面软件,也是下一代的可视化数据库设计、管理的工具,它同时有开源和商业化
- 本文实例讲述了php版微信支付api.mch.weixin.qq.com域名解析慢原因与解决方法。分享给大家供大家参考,具体如下:微信支付a
- 经常在前端面试或是和其他同行沟通是,在谈到构造在JS定义构造函数的方法是最好使用原型的方式:将方法定义到构造方法的prototype上,这样
- python中迭代器和iter()函数迭代器为类序列对象提供了一个类序列的接口。python的迭代无缝地支持序列对象,而且它还允许程序员迭代
- 面是我下载页面down.php 的php代码 现在我发现,用迅雷,谷歌浏览器直接打开,就能输出下载文件,一点不起防盗链作用。&nb
- SMTP协议首先了解SMTP(简单邮件传输协议),邮件传送代理程序使用SMTP协议来发送电邮到接收者的邮件服务器。SMTP协议只能用来发送邮
- asp函数实现把数字格式化为每3个数字时以逗号间隔的数字见下:<%Function Comma(str)If No
- 我们知道SQLSERVER的数据行的存储有两种数据结构:A: 堆 B :B树(binary 二叉树)数据按照这种两种
- 有使用过VS2005开发工具的朋友或者其他语句如js中都有Try catch 语句块,那么在mysql中是否能有SQLserver的@@er
- 事情是这样的520晚上,正跟队友 啪啪啪 组团开黑突然,微信上前女友的头像跳动了起来快一年了,难道是想要复合?发来的竟是一个 "
- 本文实例讲述了Python实现监控Nginx配置文件的不同并发送邮件报警功能。分享给大家供大家参考,具体如下:因为项目中经常涉及到多个Ngi
- 手风琴(Collapse)效果展示Bootstrap 框架中 Collapse插件(折叠)其实就是我们常见的手风琴效果。点击标题,可以让其对
- -crop参数是从一个图片截取一个指定区域的子图片.格式如下:convert -crop widthxheight{+-
- 啥是依赖规范可以以各种形式指定项目的依赖项,取决于依赖项的类型以及安装项目可能需要的可选约束版本约束^ 约束编写规范允许的版本范围^1.2.
- mysql对列求和mysql中,可以使用SELECT语句配合SUM()函数来对列求和,能够返回指定列值的总和,求和语法为&ldquo
- 1.socket黏包问题原理黏包:指数据与数据之间没有明确的分界线,导致不能正确的读取数据。应用数据想要发送数据就必须将数据交给操作系统,而
- 多数应用场景下,我们需要对重要数据进行备份、并放置到一个安全的地方,以备不时之需。常见的 MySQL 数据备份方式有,直接打包复制对应的数据
- 导读你真的知道CHAR和VARCHAR类型在存储和读取时的区别吗?还是先抛几条结论吧:1、存储的时候,CHAR总是会补足空格后再存储,不管用
- dplyr专注处理dataframe对象, 并提供更稳健的与其它数据库对象间的接口。一、5个关键的数据处理函数:select() 返回列的子