jQuery焦点图切换特效插件封装实例

2020-05-23 06:16:34易采站长站整理

            };
            wrapper.find(‘.nums’).find(‘a:eq(‘ + index + ‘)’).addClass(‘active’).siblings().removeClass
(‘active’);
            wrapper.find(‘.title’).find(‘a’).attr(‘href’, active_a.attr(‘href’)).text(active_a.attr
(‘title’));
            ul.stop().animate(param, settings.duration * 1000, settings.easing,
            function () {
                active.removeClass(‘active’);
                if (order_by == ‘ASC’) {
                    if (active.next().size()) {
                        active.next().addClass(‘active’)
                    } else {
                        order_by = ‘DESC’;
                        active.prev().addClass(‘active’)
                    }
                } else if (order_by == ‘DESC’) {
                    if (active.prev().size()) {
                        active.prev().addClass(‘active’)
                    } else {
                        order_by = ‘ASC’;
                        active.next().addClass(‘active’)
                    }
                }