css
效果如下:
1、下载本实例中的所有内容:
2、插入代码:
在<head>标签里放入下面代码:
<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript" src="js/interface.js"></script>
<link href="style.css" rel="stylesheet" type="text/css" />
<!--[if lt IE 7]>
<style type="text/css">
.dock img { behavior: url(iepngfix.htc) }
</style>
<![endif]–>
3. 设置
把下面代码放到<body>标签内。
<script type="text/javascript">
$(document).ready(
function()
{
$(’#dock2′).Fisheye(
{
maxWidth: 60,
items: ‘a’,
itemsText: ’span’,
container: ‘.dock-container2′,
itemWidth: 40,
proximity: 80,
alignment : ‘left’,
valign: ‘bottom’,
halign : ‘center’
}
)
}
);
</script>
4.添加或移除项目
<a class="dock-item" href="#"><img src="http://www.webjx.com/htmldata/2007-05-22/images/home.png" alt="home" /><span>Home</span></a>
<a class="dock-item2" href="#"><span>Home</span><img src="http://www.webjx.com/htmldata/2007-05-22/images/home.png" alt="home" /></a>
允许的浏览器:IE 6, IE 7, Opera 9, Firefox 2, Safari 2
原文连接: