Next Dot 1


#1

Hello,

I am having trouble with an exercise called: 'Next Dot 1'
If i submit my code an error message pops up saying: "Oops, try again.
Remember to remove '.active-dot' from the current dot."
Can someone help me with this? my code looks like this:

var main = function() {
    $('.dropdown-toggle').click(function() {
        $('.dropdown-menu').toggle();
    });
    
    $('.arrow-next').click() {
        var currentslide = $('.active-slide');
        var nextslide = currentslide.next();
        
        var currentdot = $('.active-dot');
        var nextdot = currentdot.next();
        
        if (nextslide.length === 0) {
            nextslide = $('.slide').first();
        
        currentslide.fadeout(600).removeclass('active-slide');
        nextslide.fadein(600).addclass('active-slide');
        
    currentdot.removeClass('active-dot');
  nextdot.addClass('active-dot');
        
    });
    
    };


$(document).ready(main);

#2

HI this part

currentslide.fadeout(600).removeclass('active-slide');
nextslide.fadein(600).addclass('active-slide');

you wrote fadeout() and fadein() instead of fadeOut() and fadeIn() with the uppercase O and I


#3

Thanks for replying,

The fadeIn and fadeOut wasnt the problem.
The problem is:

currentdot.removeClass('.active-dot');
nextdot.addClass('.active-dot');

This is the problem ^

I'm still searching for my mistake, but i can't find it yet.
It's probably something very simple, but i cant find it.


#4

I dont extactly know how, but i managed to solve my problem.


#5

currentdot.removeClass('.active-dot');
nextdot.addClass('.active-dot');

need to be

currentdot.removeClass('active-dot');
nextdot.addClass('active-dot');

No full stop infront of the active-dot as it is already defined as a Class by the removeClass/Active Class


#6

A post was split to a new topic: Why does it tell me to remove the active-dot class from the current dot? (Next Dot 1)


#7