// JavaScript Document
function breakout_of_frame()
{
  // see http://www.thesitewizard.com/archive/framebreak.shtml
  // for an explanation of this script and how to use it on your
  // own website
  if (top.location != document.location) {
    top.location.href = document.location.href ;
  }
}

function init() {
	
	breakout_of_frame();
	return true;
	
	
	if (!document.getElementById) return
	var imgOriginSrc;
	var imgTemp = new Array();
	var imgarr = document.getElementsByTagName('img');
	
	for (var i = 0; i < imgarr.length; i++) {
		if (imgarr[i].getAttribute('hsrc')) {
			if (imgarr[i].getAttribute('dsrc')) {
				var imgDown = imgarr[i].getAttribute('hsrc');
				imgarr[i].setAttribute('src',imgDown);
			} else {
				imgTemp[i] = new Image();
				imgTemp[i].src = imgarr[i].getAttribute('hsrc');
				imgarr[i].onmouseover = function() {
					imgOriginSrc = this.getAttribute('src');
					var imgNewSrc = this.getAttribute('hsrc');
					this.setAttribute('src',imgNewSrc)
				}
			}
			
			if (!(imgarr[i].getAttribute('dsrc'))) {
				imgarr[i].onmouseout = function() {
					if (typeof(imgOriginSrc) != "undefined") { 
						this.setAttribute('src',imgOriginSrc)
					}
				}
			}
		}
		
		
		if (imgarr[i].getAttribute('rsrc')) {
			var num = Math.random();
			if (num < 0.5) {
				// swap image to other ad
				var imgNewAdSrc = imgarr[i].getAttribute('rsrc');
				imgarr[i].setAttribute('src',imgNewAdSrc);
				imgarr[i].onclick = function() { 
					window.open(this.getAttribute('roc'), "_blank");
				}
			}
		}
		
		
	}
}

onload=init;





function doPopup(targetURL, targetWindow, width, height) {
	
	// targetURL+'?w='+width+'&h='+height
	
    newwindow=window.open(targetURL,targetWindow,'toolbar=0,location=0,directories=0,status=1,menubar=0,scrollbars=1,resizable=1,width='+width+',height='+height);
	
	// center popup
	var newLeft = (screen.width - width)/2;
	var newTop = (screen.height - height)/2;
	if (newLeft < 0) newLeft = 0;
	if (newTop < 0) newTop = 0;
	newwindow.moveTo(newLeft, newTop);
	
	// resize
	if (parseInt(navigator.appVersion)>3) {
		if (navigator.appName=="Netscape") {
			newwindow.outerWidth=width;
			newwindow.outerHeight=height;
		}
		else newwindow.resizeTo(width,height);
	}
	
	// bring popup to front
	if (window.focus) {
		newwindow.focus();
	}
	return false;
}









function getAdURL() {
	return;
}


function bigImage(im) {
	var newSrc = im.getAttribute('bigsrc');
	im.setAttribute('src', newSrc);
	var newWidth = im.getAttribute('bigwidth');
	im.setAttribute('width', newWidth);
	var newHeight = im.getAttribute('bigheight');
	im.setAttribute('height', newHeight);
	
	im.style.paddingLeft='0px';
	im.style.paddingBottom='30px';
	
	im.onclick = function() {
		this.style.paddingLeft='20px';
		this.style.paddingBottom='0px';
		var newSrc = this.getAttribute('smallsrc');
		this.setAttribute('src', newSrc);
		var newWidth = this.getAttribute('smallwidth');
		this.setAttribute('width', newWidth);
		var newHeight = this.getAttribute('smallheight');
		this.setAttribute('height', newHeight);
		this.onclick = function() {
			bigImage(im);
		}
	}
}