//begin blog link

blog_handle = new Object;
blog_ID = 0;

function blog(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
blog_handle = window.open("blog/nourish/index.php","blog","status=yes,menu=yes,location=no,toolbar=1,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){blog_handle.window.focus();}
}

blogbackout_handle = new Object;
blogbackout_ID = 0;

function blogbackout(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
blogbackout_handle = window.open("../blog/nourish/index.php","blogbackout","status=yes,menu=yes,location=no,toolbar=1,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){blog_handle.window.focus();}
}
//end blog link

//link for giftwrap message
giftwrap_handle = new Object;
giftwrap_ID = 0;

function giftwrap(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
giftwrap_handle = window.open("giftwrapmessage.php","giftwrap","status=yes,menu=no,location=no,toolbar=0,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){giftwrap_handle.window.focus();}
}

//begin links on product page aka shop

policies_handle = new Object;
policies_ID = 0;

function policies(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
policies_handle = window.open("shipreturn.htm","policies","status=yes,menu=no,location=no,toolbar=0,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){policies_handle.window.focus();}
}

amerforest_handle = new Object;
amerforest_ID = 0;

function amerforest(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
amerforest_handle = window.open("americanforests.htm","amerforest","status=yes,menu=no,location=no,toolbar=0,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){amerforest_handle.window.focus();}
}

//end links on product page aka shop

//begin environmental website links from why page
blueman_handle = new Object;
blueman_ID = 0;

function blueman(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
blueman_handle = window.open("bluemangroup.html","blueman","status=yes,menu=no,location=no,toolbar=0,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){blueman_handle.window.focus();}
}

climatechange_handle = new Object;
climatechange_ID = 0;

function climatechange(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
climatechange_handle = window.open("http://www.americanforests.org/campaigns/ikea/","climatechange","status=yes,menu=no,location=no,toolbar=0,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){climatechange_handle.window.focus();}
}

breathearth_handle = new Object;
breathearth_ID = 0;

function breathearth(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
breathearth_handle = window.open("http://www.breathingearth.net/","breathearth","status=yes,menu=no,location=no,toolbar=0,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){breathearth_handle.window.focus();}
}

trashmigration_handle = new Object;
trashmigration_ID = 0;

function trashmigration(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
trashmigration_handle = window.open("http://oceans.greenpeace.org/en/the-expedition/news/trashing-our-oceans/ocean_pollution_animation","trashmigration","status=yes,menu=no,location=no,toolbar=0,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){trashmigration_handle.window.focus();}
}

ecycle_handle = new Object;
ecycle_ID = 0;

function ecycle(w,h,t,r) {
if(parseInt(navigator.appVersion) >= 4){
  	r = (screen.width - w) / 2;
  	t = (screen.height - h) / 2;
  }
 var loc = 'width=' + w + ',height=' + h + ',top=' + t + ',left=' + r;
ecycle_handle = window.open("http://www.eiae.org/","ecycle","status=yes,menu=no,location=no,toolbar=0,resizable,scrollbars,directories," + loc);
if(parseInt(navigator.appVersion) >= 4){ecycle_handle.window.focus();}
}
//end environmental website links

//begin resize iframe parent script

function iFrameSize(w,h){ 
document.getElementById('testiframe').style.width=w+'px' 
document.getElementById('testiframe').style.height=h+'px'
} 

//end resize iframe parent script
