Hannah Gray wrote: > This is probably a very simple question, and I may be going about the > problem entirely the wrong way. Corrections and ideas are very welcome. > > Basically, the below code functions to hide and show divs very nicely, > but it only changes the image source on hide, not show.
Perhaps something like this? $('#toggle_year').click(function(){ var layer = $('#container_year"); var icon = this; if(layer.is(":visible")) { //hide layer layer.hide('slow'); //swap icon icon.src('changeme.gif'); } else { //show layer layer.show('slow'); icon.src('changeme'); } }); /christian _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/