// JavaScript Document

/******* show/hide all *******/
function expand_all()
{
$$('.expandable').invoke('show');
$$('.minus').each(function(e){e.src='/maidenre.com/userfiles/image/minus.gif';});
$('showall').hide();
$('hideall').show();
}
function hide_all()
{
$$('.expandable').invoke('hide');
$$('.minus').each(function(e){e.src='/maidenre.com/userfiles/image/plus.gif';});
$('showall').show();
$('hideall').hide();
}

function hide_all_expandables(p_this)
{

$$('.expandable').invoke('hide');

if($(p_this).src.endsWith('minus.gif'))
{
  //Put the minus/plus code here so the "endsWith" code above will work
  $$('.minus').each(function(e){e.src='/maidenre.com/userfiles/image/plus.gif';});
  $(p_this).up(1).down('.expandable').hide();
  $(p_this).src='/maidenre.com/userfiles/image/plus.gif';
}
else
{
  //Put the minus/plus code here so the "endsWith" code above will work
  $$('.minus').each(function(e){e.src='/maidenre.com/userfiles/image/plus.gif';});
  $(p_this).up(1).down('.expandable').show();
  $(p_this).src='/maidenre.com/userfiles/image/minus.gif';
}


}

function expand_one(p_this)
{

$$('.expandable').invoke('hide');
$(p_this).src='/maidenre.com/userfiles/image/plus.gif';
$(p_this).down('.expandable').show();
$$('.minus').each(function(e){e.src='/maidenre.com/userfiles/image/plus.gif';});
  
}

/*******  popwindow *******/
var newwindow;
function popwindow(url)
{
newwindow=window.open(url,'name','height=500,width=900,left=100,top=100,resizable=yes,scrollbars=yes,toolbar=yes,menubar=yes,location=yes,directories=yes,status=yes');
}

/*******  show/hide with images*******/

/*<![CDATA[*/
function toggleDiv(img,img1,img2,divid){
var divobj=document.getElementById(divid);
divobj.style.display=(divobj.style.display=='none')?'':'none';
img.src=(divobj.style.display=='none')?img.src.replace(img1,img2):img.src.replace(img2,img1);
}
/*]]>*/

