<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
<style type="text/css">
*{
padding: 0;
margin: 0;
}
body{
background-color: #999;
}
.cou{
width: 200px;
height: 400px;
border: 8px solid red;
margin: 30px auto;
position: relative;
}
.lun img{
width: 200px;
height: 386px;
}
.lun a{
display: none;
}
.lun a.on{
display: block;
}
.item{
position: absolute;
bottom: 5px;
left: 50%;
transform: translateX(-50%);
}
.item li{
float: left;
width: 10px;
height: 10px;
list-style: none;
border-radius: 50%;
background-color: #fff;
margin-right: 10px;
}
.item li.current{
background-color: orange;
}
.al{
width: 24px;
height: 24px;
display: inline-block;
position: absolute;
top: 174px;
background:rgba(255,255,255,0.3);
display: none;
}
.al img{
用js代码制作网页轮播图效果
最新推荐文章于 2024-06-17 12:01:08 发布
本文介绍了如何使用JavaScript编写代码来创建一个网页上的动态轮播图效果。通过控制图片的显示和隐藏,实现了轮播图的自动切换功能,同时讨论了如何添加控制按钮以便用户手动切换图片。
摘要由CSDN通过智能技术生成