可爱老人网

 找回密码
 注册会员
搜索
查看: 4486|回复: 43

【习作】根据夕阳黄昏老师代码编制

[复制链接]
发表于 2020-12-5 08:31 | 显示全部楼层 |阅读模式
本帖最后由 九品莲花 于 2023-5-20 20:39 编辑

评分

参与人数 9人气值 +34 收起 理由
禾子 + 3 大赞!
周永根 + 5 大赞!
黄煌长 + 5 大赞!
瑢芳田智 + 3 赞一个!
真真 + 5 大赞!

查看全部评分

 楼主| 发表于 2020-12-5 08:38 | 显示全部楼层
代码如下:

<style type="text/css">
#ptall div        {
        width:750px;
        height:1177px;
        background-size:cover;
        transition:3s all;
}
#ptall div:nth-child(1)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201510/11/154829bh8t0hachy8jm05t.jpg");
}
#ptall div:nth-child(2)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/050506j37735ns9n53s00a.jpg");
}
#ptall div:nth-child(3)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/050906k51u33y5yw48w13u.jpg");
}
#ptall div:nth-child(4)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/051025njoas1xnj4ycuurm.jpg");
}
#ptall div:nth-child(5)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/051154l5xz7iiuzixxv9ex.jpg");
}
#ptall div:nth-child(6)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/051300jiyhgcg96yrsw29t.jpg");
}
#ptall div:nth-child(7)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/051433d2m5iis4118jum0o.jpg");
}
#ptall div:nth-child(8)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/051539hinviehh2skk5cn7.jpg");
}
#ptall div:nth-child(9)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/051712xjzhzd5oej3mj9h9.jpg");
}
#ptall div:nth-child(10)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/051830k7mvrrlrglxnggog.jpg");
}
#ptall div:nth-child(11)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/052006qj0gwpkqopfmzgp3.jpg");
}
#ptall div:nth-child(12)        {
        background-image:url("http://bbs.foz.cn/data/attachment/forum/201606/11/052110cmugxbofuz6ubbdv.jpg");
}


#ptall div:nth-child(1):hover        {
       
}


#ptall        {
        width:750px;
        height:9000px;
        animation: pshift 48s ease-out infinite alternate;
}
#ptall:hover        {
        animation-play-state:paused;
}


#outframe        {
        width:750px;
        height:1177px;
        overflow:hidden;
        border-radius:32px;
        margin:24px auto;
        position:relative;
        border:thick brown groove;
        ----webkit-mask-image: radial-gradient(black 60%, transparent 90%);
        background:#ccf;
}


@keyframes pshift {
        0%,9% {
                margin-top: 0px;
        }


        10%,17% {
                margin-top: -1177px;
        }


        18%,25% {
                margin-top: -2354px;
        }


        26%,33% {
                margin-top: -3531px;
        }


        34%,41% {
                margin-top: -4708px;
        }


        42%,47% {
                margin-top: -5885px;
        }


        50%,57% {
                margin-top: -7062px;
        }


        58%,65% {
                margin-top: -8239px;
        }
        66%,73% {
                margin-top: -9416px;
        }
        74%,81% {
                margin-top: -10593px;
        }
        82%,90% {
                margin-top: -11770px;
        }
        91%,100% {
                margin-top: -12947px;
        }
}


</style>


<div id="outframe">
<div id="ptall">
<div ></div><div ></div><div ></div><div ></div>
<div ></div><div ></div><div ></div><div ></div>
<div ></div><div ></div><div ></div><div ></div>
</div>


</div>
</td></tr></div><embed height="1" type="application/x-shockwave-flash" width="1" src="http://images.missyuan.com/attachments/day_091119/20091119_f2b0ddc619598f0131028u22v29PBSW3.swf" wmode="opaque" allowfullscreen="true" allowscriptaccess="always">

发表于 2020-12-5 08:46 | 显示全部楼层
问好莲花斑斑,欣赏音画佳作,遥祝天天快乐!
发表于 2020-12-5 09:45 | 显示全部楼层
本帖最后由 南国地带 于 2020-12-5 11:06 编辑

试试代码(去掉音乐)

发表于 2020-12-5 09:46 | 显示全部楼层
谢谢九品版分享,阿弥陀佛
发表于 2020-12-5 09:52 | 显示全部楼层
欣赏莲花老师音画佳作,向您学习!问好!
发表于 2020-12-5 09:55 | 显示全部楼层
欣赏佳作!赞!
发表于 2020-12-5 10:04 | 显示全部楼层
阿弥陀佛欣赏九品莲花老师音画佳作,
发表于 2020-12-5 10:27 | 显示全部楼层


发表于 2020-12-5 10:39 | 显示全部楼层

  1. <style type="text/css">
  2. #ptall img        {
  3.         width:750px;
  4.         height:1177px;
  5.         background-size:cover;
  6.         transition:3s all;
  7. }


  8. #ptall        {
  9.         width:750px;
  10.         height:9000px;
  11.         animation: pshift 48s ease-out infinite alternate;
  12. }
  13. #ptall:hover        {
  14.         animation-play-state:paused;
  15. }


  16. #outframe        {
  17.         width:750px;
  18.         height:1177px;
  19.         overflow:hidden;
  20.         border-radius:32px;
  21.         margin:24px auto;
  22.         position:relative;
  23.         border:thick brown groove;
  24.         ----webkit-mask-image: radial-gradient(black 60%, transparent 90%);
  25.         background:#ccf;
  26. }


  27. @keyframes pshift {
  28.         0%,9% {
  29.                 margin-top: 0px;
  30.         }


  31.         10%,17% {
  32.                 margin-top: -1177px;
  33.         }


  34.         18%,25% {
  35.                 margin-top: -2354px;
  36.         }


  37.         26%,33% {
  38.                 margin-top: -3531px;
  39.         }


  40.         34%,41% {
  41.                 margin-top: -4708px;
  42.         }


  43.         42%,47% {
  44.                 margin-top: -5885px;
  45.         }


  46.         50%,57% {
  47.                 margin-top: -7062px;
  48.         }


  49.         58%,65% {
  50.                 margin-top: -8239px;
  51.         }
  52.         66%,73% {
  53.                 margin-top: -9416px;
  54.         }
  55.         74%,81% {
  56.                 margin-top: -10593px;
  57.         }
  58.         82%,90% {
  59.                 margin-top: -11770px;
  60.         }
  61.         91%,100% {
  62.                 margin-top: -12947px;
  63.         }
  64. }


  65. </style>


  66. <div id="outframe">
  67. <div id="ptall">
  68. <img src="http://bbs.foz.cn/data/attachment/forum/201510/11/154829bh8t0hachy8jm05t.jpg">
  69. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/050506j37735ns9n53s00a.jpg">
  70. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/050906k51u33y5yw48w13u.jpg">
  71. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/051025njoas1xnj4ycuurm.jpg">
  72. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/051154l5xz7iiuzixxv9ex.jpg">
  73. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/051300jiyhgcg96yrsw29t.jpg">
  74. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/051433d2m5iis4118jum0o.jpg">
  75. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/051539hinviehh2skk5cn7.jpg">
  76. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/051712xjzhzd5oej3mj9h9.jpg">
  77. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/051830k7mvrrlrglxnggog.jpg">
  78. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/052006qj0gwpkqopfmzgp3.jpg">
  79. <img src="http://bbs.foz.cn/data/attachment/forum/201606/11/052110cmugxbofuz6ubbdv.jpg">

  80. </div>

  81. </div>
复制代码



代码可以简化一些,不必太复杂。
        
下一页 发布主题 快速回复

手机版|公众号|小黑屋|可爱老人网

GMT+8, 2025-2-24 09:10

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表