Ugh! That's what I get for not testing.
Your code had an error:
$("dd:visible)")
should be ... $("dd:visible") So the whole thing... $(document).ready(function(){ $("dd:not(:first)").hide(); $("dt a").click(function(){ var $next = $(this).parent().next(); if ($next.is(':visible')) { $("dd:visible").slideUp("slow"); } else { $("dd:visible").slideUp("slow"); $next.slideDown("slow"); } return false; }); }); --Karl _________________ Karl Swedberg www.englishrules.com www.learningjquery.com On May 16, 2008, at 2:25 PM, Karl Swedberg wrote:
$(document).ready(function(){ $("dd:not(:first)").hide(); $("dt a").click(function(){ var $next = $(this).parent().next(); if ($next.is(':visible') { $("dd:visible)").slideUp("slow"); } else { $("dd:visible)").slideUp("slow"); $next.slideDown("slow"); } return false; }); });