Lyrics

js 轮播图,点击某个圆点跳转到某张图片

1.  button[ j ].index = i;  //j 就是获取到的那个下标  

2. 因为index是自定义属性所以必须使用 getAttribute 属性去获取index 的属性


var clickIndex = paseInt(this . getAttribute('index');

https://www.cnblogs.com/LIUYANZUO/p/5679753.html; 教程


评论