var vp360JsUrl = "http://vp360hosting.com/BASE_CODE/flash_script.loader.php?client_id=CALLMD&video_id=135&referrer_engine="+referrer_engine+"&referrer_keyword="+referrer_keyword;

var vp360Browser = document.all && !window.opera;
  var vp360BrowserBody = ( document.compatMode=='CSS1Compat' ) ?  document.documentElement : document.body;
  var vp360BrowserHeight = ( vp360Browser ) ? vp360BrowserBody.clientHeight : window.innerHeight;

  var vp360BrowserWidth = ( vp360Browser ) ? vp360BrowserBody.clientWidth : window.innerWidth;
  var vp360BrowserTop = ( vp360Browser ) ? vp360BrowserBody.scrollTop : window.pageYOffset;
  var vp360BrowserLeft = ( vp360Browser ) ? vp360BrowserBody.scrollLeft : window.pageXOffset;

  function  _vp360Init () {

  var vp360DomElement  = document.createElement( 'script' );
  vp360DomElement.setAttribute( 'type', 'text/javascript' );
  vp360DomElement.setAttribute( 'src', vp360JsUrl  );

  var vp360Container = document.body.firstChild;
  ( vp360Container ) ? document.body.insertBefore( vp360DomElement, vp360Container ) :  document.body.appendChild( vp360DomElement );

  }

  function loadVp360() {
	_vp360Init();
  }

function video1()
{

	test= window.open("/video1/","blank","toolbar=no,width=470,height=300");
	test.moveTo(350,50);
}

function gayles()
{
	test= window.open("/gayles/","blank","toolbar=no,width=730,height=440");
	test.moveTo(350,50);

	
}

function video2()
{

	test= window.open("/video2/","blank","toolbar=no,width=470,height=300");
	test.moveTo(350,50);
}

function video3()
{

	test= window.open("/video3/","blank","toolbar=no,width=470,height=300");
	test.moveTo(350,50);
}

function video4()
{

	test= window.open("/video4/","blank","toolbar=no,width=470,height=300");
	test.moveTo(350,50);
}

function out()
{
	document.getElementById('search').src='/media/promo2 images/images/butt-search.png';
}

 	 // You may specify partial version numbers, such as "1" or "1.3",
 	 //  with the same result. Doing so will automatically load the 
  	//  latest version matching that partial revision pattern 
  	//  (i.e. both 1 and 1.3 would load 1.3.2 today).
  	google.load("jquery", "1.4.2");
 
  google.setOnLoadCallback(function() {
    // Place init code here instead of $(document).ready()
  });

function submenu(item,src)
{
    if (src=='subdomain') item_src='/media/menu/'+item+'-roll-new.png';
    else item_src='/media/menu/'+item+'-roll.png';
    document.getElementById('menus').src=item_src;
    item_=document.getElementById(item)
    if (item_) item_.style.display='block';
}

function pops(src)
{
    if (src=='subdomain')
        document.getElementById('menus').src='/media/menu/base-nav-new.png';
    else document.getElementById('menus').src='/media/menu/base-nav.png';
    document.getElementById('medical').style.display='none';
    document.getElementById('drugs').style.display='none';
    document.getElementById('weight').style.display='none';
    document.getElementById('mental').style.display='none';
    document.getElementById('lifestyle').style.display='none';
    health_=document.getElementById('health');
    if (health_) health_.style.display='none';
    partners_=document.getElementById('partners');
    if (partners_) partners_.style.display='none';
}

	function login(showhide){
			if(showhide == "show"){
				document.getElementById('popupbox').style.visibility="visible"; /* If the function is called with the variable 'show', show the login box */
			}else if(showhide == "hide"){
				document.getElementById('popupbox').style.visibility="hidden"; /* If the function is called with the variable 'hide', hide the login box */
			}
	}

