The JD carousel was implemented using pure HTML and CSS, without adding dynamic effects, and mainly using positioning knowledge.
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>LunBo</title> <style> *{ padding: 0; margin: 0; } li{ list-style: none; } .lunbo{ margin: 40px auto; height: 470px; width: 590px; position: relative; } .left,.right{ position: absolute; top: 50%; margin-top: -18px; width: 24px; height: 36px; } .left{ left: 0; } .right{ right: 0; } .lunbo ul{ height: 18px; width: 151px; background: rgba(255,255,255,.3); position: absolute; bottom: 10px; left: 50%; margin-left: -76px; border-radius: 10px; } .lunbo li{ height: 14px; width: 14px; border-radius: 50%; background-color: #fff; float: left; margin: 2px; } .lunbo .current{ background-color: #f40; } </style> </head> <body> <div class="lunbo"> <img src="images/lunbo.jpg" alt=""> <div class="left"><img src="images/left.png" alt=""></div> <!-- You can also use a link and then use background --> <div class="right"><img src="images/right.png" alt=""></div> <ul> <li class="current"></li> <li></li> <li></li> <li></li> <li></li> <li></li> <li></li> <li></li> </ul> </div> </body> </html> The following effects were achieved Summarize The above is the pure HTML and CSS to achieve the JD carousel effect introduced by the editor. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website! |
<<: The unreasonable MaxIdleConns of MySQL will cause short connections
>>: Five practical tips for web form design
I just want to make a small thing that combines w...
The version of vsCode has been updated in recent ...
In the process of team development, it is essenti...
Design Intentions When developing a page, you oft...
Error: Connection to blog0@localhost failed. [080...
Two days ago, I took advantage of the Double 11 s...
Table of contents 1. Lvs Introduction 2. Lvs load...
Maybe everyone knows that js execution will block...
Table of contents Introduction What does an itera...
This article shares the specific code of the vue3...
Table of contents 1. What is Promise? 2. Why is t...
1. Overview The image in Docker is designed in la...
Table of contents 1. Create a watermark Js file 2...
Table of contents Purpose Experimental environmen...
Keepalived+Nginx+Tomcat to achieve high availabil...