function showLarge(){
  if (document.getElementById('img_lg')){
    hideExcept(0);
    $$('#img_sm li').each(function(li_small){
      li_small.addClassName('click-me')
			li_small.observe('click', function(event){
        var img_id = li_small.identify().split('_')[1];
        hideExcept(img_id);
      })
    });
  }
}

function hideExcept(show_id){
  $$('#img_lg li').each(function(li){
		if (li.identify().split('_')[1] == show_id){
      li.show();
    }else{
      li.hide();
    }
  });
}

document.observe("dom:loaded", function() {
	showLarge();
});
