window.setTimeout( "breakOut()", 1000 );

function breakOut() {
	if( window != top ) {
		top.location.href = self.location.href;
	}
}

/*
**
** A flexible yet standards-compliant
**   window pop-up manager
**
** based on combining the practices and great insight from:
**
**   - http://youngpup.net/?request=/snippets/soopa-pop.xml
**   - http://www.sitepoint.com/article/1041/3
**
** Copyright (c) 2004 Cosbit Technologies
**
**   http://cosbit.com  /  michael.burns@cosbit.com
**
*/

function cosbitPopSetup() {

  // check DOM compatibility
  if (!document.getElementsByTagName) return;

  var as = document.getElementsByTagName("a");
  for (var i=0; i<as.length; i++) {
    var a = as[i];
    if (a.getAttribute("href") && a.getAttribute("rel")) {
      var r = a.getAttribute("rel");
      if (r.indexOf("_cosbitPop") == 0)
        a.onclick = cosbitPop;
      else if (r.indexOf("_") == 0)
        a.target = r;
    }
  }
}

function cosbitPop() {
  var attrs = this.getAttribute("rel").split(":");
  var sFeatures = attrs[1];
  window.open(this.href, attrs.length > 2 ? attrs[2] : String((new Date()).getTime()), sFeatures);
  return false;
}

window.setTimeout( 'cosbitPopSetup()', 100 );

