The n shortcut 2


#1

I need help with my code. I read all of the help topics on this one and I still can't get this one to run.

Can someone please tell me what I'm missing?

var main = function() {
$('.article').click(function() {
$('.description').hide();
$(this).children('.description').show();
$(this).addClass('current');
});

$(document).keypress(function(event) {
if(event.which === 111) {
$('.current').children('.description').toggle();
}
else if(event.which === 110) {
var currentArticle = $('.current');
var nextArticle = currentArticle.next();

     currentAticle.removeClass('current');
     nextArticle.addClass('current');
 }

});
};

$(document).ready.(main);


#2

Oh for crying out loud...

I have a typo on Article and a period after ready.... smacks self REALLY hard..


#3

Dude it happens. Frustrating as all heck, but it's all part of the process.