function visibility(obj) {

  if (!obj.style.display) { obj.style.display = 'none'; }

  if(obj.style.display == 'none') {
    obj.style.display = 'block';

  } else {
    obj.style.display = 'none';
  }
}

function updateHeightOfBanner(width,height)
{
	if(!window.parent)		
	{
		return false;
	}
	
	if(window.parent == self)		
	{
		return false;
	}
	
	var aframes = window.parent.document.getElementsByTagName("iframe");	

	var location = ""+window.location
	for(var i=0; i<aframes.length; i++)
	{
		var frame=aframes.item(i);
			
		if(location.lastIndexOf(frame.src) != -1)
		{
			frame.height = height+"px";
			frame.width = width+"px";
			break;
		}
	}
}

function autoresize_image(image)
{
	limit = 480;
	if(image.width > limit)
	{
		if(document.all)
		{
			image.style.cursor = 'hand';
		}
		else
		{
			image.style.cursor = 'pointer';
		}
		image.style.width = limit + 'px';
		image.onclick = function() {
			image = window.open(this.src, 'image', 'width=700,height=500,resizable=1,scrollbars=1');
		}
	}
	//image.style.display="block";
}
