jquery 轮播 首尾相接

一、轮播时候首尾不衔接 当从最后一张调到第一张 或者 从第一张调到最后一张时候 过渡的时候长度过大(好几张图片的宽度)体验不好<!DOCTYPE html><html><head> <meta charset="utf-8" name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, use
摘要由CSDN通过智能技术生成

一、轮播时候首尾不衔接 当从最后一张调到第一张 或者 从第一张调到最后一张时候 过渡的时候长度过大(好几张图片的宽度)体验不好

<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8" name="viewport"
        content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <title>JQuery轮播图头尾不循环 体验较差</title>
    <script src="./js/jquery.js"></script>
    <style>
        * {
            padding: 0;
            margin: 0;
        }

        .container {
            width: 600px;
            height: 400px;
            overflow: hidden;
            position: relative;
            margin: 0 auto;
        }

        .list {
            width: 3000px;
            height: 400px;
            position: absolute;

        }

        .list>img {
            float: left;
            width: 600px;
            height: 400px;
        }

        .pointer {
            position: absolute;
            width: 100px;
            bottom: 20px;
            left: 250px;
        }

        .pointer>span {
            cursor: pointer;
            display: inline-block;
            width: 10px;
            height: 10px;
            background: #7b7d80;
            border-radius: 50%;
            border: 1px solid #fff;
        }

        .pointer .on {
            background: #28a4c9;
        }

        .arrow {
            position: absolute;
            text-decoration: none;
            width: 40px;
            height: 40px;
            background: #727d8f;
            color: #fff;
            font-weight: bold;
            line-height: 40px;
            text-align: center;
            top: 180px;
            display: none;
        }

        .arrow:hover {
            background: #0f0f0f;
        }

        .left {
            left: 0;
        }

        .right {
            right: 0;
        }

        .container:hover .arrow {
            display: block;
        }
    </style>
</head>

<body>
    <div class="container">
        <div class="list" style="left:0px;">
            <!--<img src="../static/image/photo1.jpg" alt="5"/>-->
            <img src="./image/a.jpg" alt="1" />
            <img src=".//image/b.jpg" alt="2" />
            <img src="./image/c.jpg" alt="3" />
            <img src="./image/d.jpg" alt="4" />
            <img src&
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 4
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值