

function getWinSize(){
	var iHeight = 0;

	if (document.documentElement && document.documentElement.clientHeight){

		iHeight = parseInt(document.documentElement.offsetHeight,10);
	}
	else if (document.body){
		iWidth = parseInt(document.body.offsetWidth,10);

	}

	return (iHeight);
}

function getWinSizeW(){
	var iWidth = 0;

	if (document.documentElement && document.documentElement.clientHeight){
		iWidth = parseInt(document.documentElement.offsetWidth,10);
	}
	else if (document.body){
		iWidth = parseInt(document.body.offsetWidth,10);
	}

	return (iWidth);
}
function f()
{
var center;
var vcenter;
var globe;
var vglobe;
var logo;
center=0;



content_width=screen.width-300;
//ifrtbl_width=document.body.offsetWidth-30;
ifrtbl_width=getWinSizeW()-30;
if (!window.innerWidth)
content_height=(getWinSize()-200);
else 
content_height=(window.innerHeight-200);

content_height=screen.height-470;
content_height=405;
if (content_height<505)
content_height=505;
content_height=500;
emp_height=475;

if (emp_height<=405)
emp_height=355
vcenter=0;
vglobe=vcenter+65+20;
leftmenu_top=78;
leftmenu_left=10;
leftmenu1_left=78;
globe=-center;
content_left=220;
content_top=20;
logo=720+center-39;
//full_width=getWinSizeW();
//if (full_width<800)
full_width=screen.width-18;
leftmenu1_top=0;
document.writeln('<style type="text/css">body {	margin-left:'+center+"px;margin-top:"+vcenter+"px;}#mid {position:absolute;width:200px;height:115px;	z-index:2;left:"+globe+"px;	top: "+vglobe+"px;}#leftmenu {	position:absolute;	width:275px;	height:115px;	z-index:3;	left:"+leftmenu_left+"px;top: "+leftmenu_top+"px;align:left;}}#leftmenu1 {	position:absolute;	width:155px;margin-top:70px;	height:115px;	z-index:0;	left:"+leftmenu_left+"px;top: "+leftmenu1_top+"px;align:left;valign:top;}#leftmenu1 {	position:absolute;	width:155px;	height:115px;	z-index:3;	left:"+leftmenu1_left+"px;top: "+90+"px;align:center;}#content{	position:absolute;	width:229px;	height:"+content_height+"px;	z-index:3;	left:"+content_left+"px;top:"+content_top+"px;}.cont{width:"+content_width+"px;height:"+content_height+"px} .emp{width:"+10+"px;height:"+emp_height+"px;} .ifrtbl{width:"+ifrtbl_width+"px;align:left;}.full{width:"+100+"%;}</style>");
}


function popup(type_) {

        x = 50;
        y = 50;
		w=600;
		h=260;

       var popupWindow = window.open('#',"",'width='+w+',height='+h+',left='+x+',top='+y+',screenX='+x+',screenY='+y);
if (type_="world")
site="<strong>What is ConnectTo World?</strong> <br><br>ConnectTo World is an exclusive program offering FREE calls to any ConnectTo customer which has ConnectTo as his/her local carrier.   You can make a call to any ConnectTo local customer for free no matter where they're located.  Be that the traditional phone service or digital VoIP service... Whether in the US, Europe, Asia or any location.  Thus, if you currently pay for calls to a destination which you frequently or even infrequently make calls to, all of these calls can be free if you refer them to become our local customer.  In addition to speaking for free, local customers can also see each other for free via our video phones.  You'll be doing yourself a favor...<br><p align='center'><a href='#' onclick='javascript:window.close();'>Close</a></p>";

popupWindow.document.write(site);
popupWindow.document.close();
return 0;
      }


//v1.0
//Copyright 2006 Adobe Systems, Inc. All rights reserved.
function AC_AddExtension(src, ext)
{
  if (src.indexOf('?') != -1)
    return src.replace(/\?/, ext+'?'); 
  else
    return src + ext;
}

function AC_Generateobj(objAttrs, params, embedAttrs) 
{ 
  var str = '<object ';
  for (var i in objAttrs)
    str += i + '="' + objAttrs[i] + '" ';
  str += '>';
  for (var i in params)
    str += '<param name="' + i + '" value="' + params[i] + '" /> ';
  str += '<embed ';
  for (var i in embedAttrs)
    str += i + '="' + embedAttrs[i] + '" ';
  str += ' ></embed></object>';

  document.write(str);
}

function AC_FL_RunContent(){
  var ret = 
    AC_GetArgs
    (  arguments, ".swf", "movie", "clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
     , "application/x-shockwave-flash"
    );
  AC_Generateobj(ret.objAttrs, ret.params, ret.embedAttrs);
}

function AC_SW_RunContent(){
  var ret = 
    AC_GetArgs
    (  arguments, ".dcr", "src", "clsid:166B1BCA-3F9C-11CF-8075-444553540000"
     , null
    );
  AC_Generateobj(ret.objAttrs, ret.params, ret.embedAttrs);
}

function AC_GetArgs(args, ext, srcParamName, classid, mimeType){
  var ret = new Object();
  ret.embedAttrs = new Object();
  ret.params = new Object();
  ret.objAttrs = new Object();
  for (var i=0; i < args.length; i=i+2){
    var currArg = args[i].toLowerCase();    

    switch (currArg){	
      case "classid":
        break;
      case "pluginspage":
        ret.embedAttrs[args[i]] = args[i+1];
        break;
      case "src":
      case "movie":	
        args[i+1] = AC_AddExtension(args[i+1], ext);
        ret.embedAttrs["src"] = args[i+1];
        ret.params[srcParamName] = args[i+1];
        break;
      case "onafterupdate":
      case "onbeforeupdate":
      case "onblur":
      case "oncellchange":
      case "onclick":
      case "ondblClick":
      case "ondrag":
      case "ondragend":
      case "ondragenter":
      case "ondragleave":
      case "ondragover":
      case "ondrop":
      case "onfinish":
      case "onfocus":
      case "onhelp":
      case "onmousedown":
      case "onmouseup":
      case "onmouseover":
      case "onmousemove":
      case "onmouseout":
      case "onkeypress":
      case "onkeydown":
      case "onkeyup":
      case "onload":
      case "onlosecapture":
      case "onpropertychange":
      case "onreadystatechange":
      case "onrowsdelete":
      case "onrowenter":
      case "onrowexit":
      case "onrowsinserted":
      case "onstart":
      case "onscroll":
      case "onbeforeeditfocus":
      case "onactivate":
      case "onbeforedeactivate":
      case "ondeactivate":
      case "type":
      case "codebase":
        ret.objAttrs[args[i]] = args[i+1];
        break;
      case "width":
      case "height":
      case "align":
      case "vspace": 
      case "hspace":
      case "class":
      case "title":
      case "accesskey":
      case "name":
      case "id":
      case "tabindex":
        ret.embedAttrs[args[i]] = ret.objAttrs[args[i]] = args[i+1];
        break;
      default:
        ret.embedAttrs[args[i]] = ret.params[args[i]] = args[i+1];
    }
  }
  ret.objAttrs["classid"] = classid;
  if (mimeType) ret.embedAttrs["type"] = mimeType;
  return ret;
}

f();

