<!-- Start of Zopim Live Chat Script -->
//document.write(unescape("%3Cscript src='" + document.location.protocol + "//zopim.com/?07x8kiFITllRSuwhB8oJORuxybZGYznh' type='text/javascript'%3E%3C/script%3E"));
<!-- End of Zopim Live Chat Script -->

var isNN = (navigator.appName.indexOf("Netscape")!=-1);

function autoTab(input,len, e) {
  var keyCode = (isNN) ? e.which : e.keyCode; 
  var filter = (isNN) ? [0,8,9] : [0,8,9,16,17,18,37,38,39,40,46];
  if(input.value.length >= len && !containsElement(filter,keyCode)) {
    input.value = input.value.slice(0, len);
    input.form[(getIndex(input)+1) % input.form.length].focus();
  }

  function containsElement(arr, ele) {
    var found = false, index = 0;
    while(!found && index < arr.length)
    if(arr[index] == ele)
    found = true;
    else
    index++;
    return found;
  }

  function getIndex(input) {
    var index = -1, i = 0, found = false;
    while (i < input.form.length && index == -1)
    if (input.form[i] == input)index = i;
    else i++;
    return index;
  }
  return true;
}
function remember(which) { //Remember me checkbox on member login page.
	if (which == 'checkbox') {
		if (document.forms[0].checkbox.checked) {
			document.forms[0].checkbox.checked = false;
		} else {
			document.forms[0].checkbox.checked = true;
		}
	}
	if (which == 'same') {
		if (document.forms[0].same.checked) {
			document.forms[0].same.checked = false;
		} else {
			document.forms[0].same.checked = true;
		}
	}
	if (which == 'enablemarketing') {
		if (document.forms[0].enablemarketing.checked) {
			document.forms[0].enablemarketing.checked = false;
		} else {
			document.forms[0].enablemarketing.checked = true;
		}
	}
	if (which == 'termsandconditions') {
		if (document.forms[0].termsandconditions.checked) {
			document.forms[0].termsandconditions.checked = false;
		} else {
			document.forms[0].termsandconditions.checked = true;
		}
	}
}
function toUnicode(elmnt,content){
    if (content.length == elmnt.maxLength){
      next = elmnt.tabIndex
      if (next < document.forms[0].elements.length) {
        document.forms[0].elements[next].focus();
    }
  }
}
function getPassword(url, name, width, height, position) {
	GP_AdvOpenWindow(url,name,'fullscreen=no,toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=no,channelmode=no,directories=no',width,height,position,'ignoreLink','',0,'',0,1,5,'');
}
function swapNavBarImage(path, group, imgName, btnName) {
	var image = path + imgName;
	var button = btnName;
	MM_nbGroup('down',group,button,image,1);
}
function preloadImages() {
	//correctPNG();
	MM_preloadImages('/images/btn_learn_sel.gif','/images/btn_learn_over.gif','/images/btn_tools_sel.gif','/images/btn_tools_over.gif','/images/btn_subscribe_sel.gif','/images/btn_subscribe_over.gif','/images/btn_support_sel.gif','/images/btn_support_over.gif','/images/btn_aboutus_sel.gif','/images/btn_aboutus_over.gif','/images/btn_contactus_sel.gif','/images/btn_contactus_over.gif','/images/btn_instantcallback.gif','/images/btn_instantcallback_over.gif','/images/btn_memberlogin_over.gif');
	MM_preloadImages('/images/bkgrd_instantcallback.png');
}
function popupCheck() {
	var popup = parseURLForParam("redirect");
	if (popup == 'requestpassword') {
		forgotPassword();
	}
}
function setTab(param1, param2) {
	if (param1 == 'gallery1thumbids') {
		for (i = 0; i < gallery1thumbids.length; i++) {
			document.getElementById(gallery1thumbids[i]).className = "gallery_thumb";
		}
	}
	if (param1 == 'gallery2thumbids') {
		for (i = 0; i < gallery2thumbids.length; i++) {
			document.getElementById(gallery2thumbids[i]).className = "gallery_thumb";
		}
	}
	document.getElementById(param2).className = "gallery_thumb_selected";
}
function setImage(param1, param2) {
	if (param1 == 'gallery1') {
		document.getElementById('GalleryImage').innerHTML = '<img src="'+ gallery1images[param2] +'" width="596" height="479">';
		document.getElementById('Title').innerHTML = gallery1titles[param2];
	}
	if (param1 == 'gallery2') {
		document.getElementById('GalleryImage').innerHTML = '<img src="'+ gallery2images[param2] +'" width="596" height="479">';
		document.getElementById('Title').innerHTML = gallery2titles[param2];
	}
}
function loadGallery(param1, param2, param3, param4, param5) {
	var layerHeight = document.body.scrollHeight;
	var clientHeight = document.body.clientHeight;
	var topPosition = Math.round(((clientHeight / 2) - 306) + document.body.scrollTop);
	document.getElementById(param1).style.top = topPosition;
	var oDiv = document.createElement("div");
	oDiv.id = "instantCallback_Dialog";
	oDiv.style.height = layerHeight;
	document.body.appendChild(oDiv);
	
	if (param5 == 'gallery1title') {	 // Set default title.
		document.getElementById("Title").innerHTML = gallery1_default_title;
	}
	if (param5 == 'gallery2title') {	 // Set default title.
		document.getElementById("Title").innerHTML = gallery2_default_title;
	}	
	if (param3 == 'gallery1images') { // Set default image.
		document.getElementById('GalleryImage').innerHTML = '<img src="'+ gallery1images[0] +'" width="596" height="479">';
	}
	if (param3 == 'gallery2images') { // Set default image.
		document.getElementById('GalleryImage').innerHTML = '<img src="'+ gallery2images[0] +'" width="596" height="479">';
	}
	if (param2 == 'gallery1thumbs') {
		var thumbdata = "";
		var thumbid = "";
		
		thumbdata = '<table height="71" border="0" cellspacing="0" cellpadding="0" align="center">';
		thumbdata += '<tr>';
		
		if (gallery1thumbs.length != 1) {
			for (i = 0; i < gallery1thumbs.length; i++) {
				thumbid = 'thumb_' + i;
				if (i == 0) {
					thumbdata += '<td width="74" align="center"><img src="'+ gallery1thumbs[i] +'" width="72" height="52" id="'+ thumbid +'" onClick="setTab(\'gallery1thumbids\',this.id);setImage(\'gallery1\','+ i +');" class="gallery_thumb_selected"></td>';
				} else {
					thumbdata += '<td width="74" align="center"><img src="'+ gallery1thumbs[i] +'" width="72" height="52" id="'+ thumbid +'" onClick="setTab(\'gallery1thumbids\',this.id);setImage(\'gallery1\','+ i +');" class="gallery_thumb"></td>';	
				}
				thumbdata += '<td width="15">&nbsp;</td>';
			}
		} else {
			thumbdata += '<td>&nbsp;</td>';
		}
		
		thumbdata += '</tr>';
		thumbdata += '</table>';
		document.getElementById('GalleryThumbs').innerHTML = thumbdata;
	}
	if (param2 == 'gallery2thumbs') {
		var thumbdata = "";
		var thumbid = "";
		
		thumbdata = '<table height="71" border="0" cellspacing="0" cellpadding="0" align="center">';
		thumbdata += '<tr>';
		
		if (gallery2thumbs.length != 1) {		
			for (i = 0; i < gallery2thumbs.length; i++) {
				thumbid = 'thumb_' + i;
				if (i == 0) {
					thumbdata += '<td width="74" align="center"><img src="'+ gallery2thumbs[i] +'" width="72" height="52" id="'+ thumbid +'" onClick="setTab(\'gallery2thumbids\',this.id);setImage(\'gallery2\','+ i +');" class="gallery_thumb_selected"></td>';
				} else {
					thumbdata += '<td width="74" align="center"><img src="'+ gallery2thumbs[i] +'" width="72" height="52" id="'+ thumbid +'" onClick="setTab(\'gallery2thumbids\',this.id);setImage(\'gallery2\','+ i +');" class="gallery_thumb"></td>';	
				}
				thumbdata += '<td width="15">&nbsp;</td>';
			}
		} else {
			thumbdata += '<td>&nbsp;</td>';
		}
		
		thumbdata += '</tr>';
		thumbdata += '</table>';
		document.getElementById('GalleryThumbs').innerHTML = thumbdata;
	}
	
	if (browser == 'Internet Explorer') {
		document.getElementById(param1).style.visibility = "visible";
	} else {
		Effect.Appear(param1);
	}
}
function loadGalleryOverlay(param1, param2, param3, param4, param5) {
	if (browser == 'Internet Explorer') {
		var galleryPopUpOverlay = '<div id="GalleryPopUp" style="position:absolute; width:908px; height:652px; z-index:200; visibility:hidden;">';
	} else {
		var galleryPopUpOverlay = '<div id="GalleryPopUp" style="position:absolute; width:908px; height:652px; z-index:200; display:none;">';
	}
	galleryPopUpOverlay += '<div id="GalleryClose"><a href="javascript:closePopUp(\'GalleryPopUp\');"><img src="/images/spacer.gif" width="25" height="25" border="0"></a></div>';
	galleryPopUpOverlay += '<div id="GalleryImage"></div>';
	galleryPopUpOverlay += '<div id="GalleryThumbs" style="border-top:1px solid #cccccc"></div>';
	galleryPopUpOverlay += '<div id="GalleryTitle">';
	galleryPopUpOverlay += '<table width="868" height="40" border="0" cellpadding="0" cellspacing="0" class="content_gallery_title">';
	galleryPopUpOverlay += '<tr>';
	galleryPopUpOverlay += '<td align="center"><div id="Title"></div></td>';
	galleryPopUpOverlay += '</tr>';
	galleryPopUpOverlay += '</table>';
	galleryPopUpOverlay += '</div>';
	galleryPopUpOverlay += '<img src="/images/bkgrd_samples_popup.png" width="908" height="652"></div>';
	document.getElementById('GalleryOverlay').innerHTML = galleryPopUpOverlay;

	var layerHeight = document.body.scrollHeight;
	var clientHeight = document.body.clientHeight;
	var topPosition = Math.round(((clientHeight / 2) - 306) + document.body.scrollTop);
	document.getElementById(param1).style.top = topPosition;
	var oDiv = document.createElement("div");
	oDiv.id = "instantCallback_Dialog";
	oDiv.style.height = layerHeight;
	document.body.appendChild(oDiv);
	
	if (param5 == 'gallery1title') {	 // Set default title.
		document.getElementById("Title").innerHTML = gallery1_default_title;
	}
	if (param5 == 'gallery2title') {	 // Set default title.
		document.getElementById("Title").innerHTML = gallery2_default_title;
	}	
	if (param3 == 'gallery1images') { // Set default image.
		document.getElementById('GalleryImage').innerHTML = '<img src="'+ gallery1images[0] +'" width="596" height="479">';
	}
	if (param3 == 'gallery2images') { // Set default image.
		document.getElementById('GalleryImage').innerHTML = '<img src="'+ gallery2images[0] +'" width="596" height="479">';
	}
	if (param2 == 'gallery1thumbs') {
		var thumbdata = "";
		var thumbid = "";
		
		thumbdata = '<table height="71" border="0" cellspacing="0" cellpadding="0" align="center">';
		thumbdata += '<tr>';
		
		if (gallery1thumbs.length != 1) {
			for (i = 0; i < gallery1thumbs.length; i++) {
				thumbid = 'thumb_' + i;
				if (i == 0) {
					thumbdata += '<td width="74" align="center"><img src="'+ gallery1thumbs[i] +'" width="72" height="52" id="'+ thumbid +'" onClick="setTab(\'gallery1thumbids\',this.id);setImage(\'gallery1\','+ i +');" class="gallery_thumb_selected"></td>';
				} else {
					thumbdata += '<td width="74" align="center"><img src="'+ gallery1thumbs[i] +'" width="72" height="52" id="'+ thumbid +'" onClick="setTab(\'gallery1thumbids\',this.id);setImage(\'gallery1\','+ i +');" class="gallery_thumb"></td>';	
				}
				thumbdata += '<td width="15">&nbsp;</td>';
			}
		} else {
			thumbdata += '<td>&nbsp;</td>';
		}
		
		thumbdata += '</tr>';
		thumbdata += '</table>';
		document.getElementById('GalleryThumbs').innerHTML = thumbdata;
	}
	if (param2 == 'gallery2thumbs') {
		var thumbdata = "";
		var thumbid = "";
		
		thumbdata = '<table height="71" border="0" cellspacing="0" cellpadding="0" align="center">';
		thumbdata += '<tr>';
		
		if (gallery2thumbs.length != 1) {
			for (i = 0; i < gallery2thumbs.length; i++) {
				thumbid = 'thumb_' + i;
				if (i == 0) {
					thumbdata += '<td width="74" align="center"><img src="'+ gallery2thumbs[i] +'" width="72" height="52" id="'+ thumbid +'" onClick="setTab(\'gallery2thumbids\',this.id);setImage(\'gallery2\','+ i +');" class="gallery_thumb_selected"></td>';
				} else {
					thumbdata += '<td width="74" align="center"><img src="'+ gallery2thumbs[i] +'" width="72" height="52" id="'+ thumbid +'" onClick="setTab(\'gallery2thumbids\',this.id);setImage(\'gallery2\','+ i +');" class="gallery_thumb"></td>';	
				}
				thumbdata += '<td width="15">&nbsp;</td>';
			}
		} else {
			thumbdata += '<td>&nbsp;</td>';
		}
		
		thumbdata += '</tr>';
		thumbdata += '</table>';
		document.getElementById('GalleryThumbs').innerHTML = thumbdata;
	}
	
	if (browser == 'Internet Explorer') {
		document.getElementById(param1).style.visibility = "visible";
	} else {
		Effect.Appear(param1);
	}
	correctPNG();
}
function loadVideo(param1, param2, param3, param4) {
	var layerHeight = document.body.scrollHeight;
	var clientHeight = document.body.clientHeight;
	var topPosition = Math.round(((clientHeight / 2) - 254) + document.body.scrollTop);
	document.getElementById(param1).style.top = topPosition;
	if (document.getElementById('instantCallback_Dialog') == undefined) {
		var oDiv = document.createElement("div");
		oDiv.id = "instantCallback_Dialog";
		oDiv.style.height = layerHeight;
		document.body.appendChild(oDiv);
	}
	
	var flash;
	
	if (param4 != '' || param4 != undefined) {
		flash = "<param name=movie value=\""+ param4 +"\">";
		flash += "<param name=quality value=high>";
		flash += "<param name=\"wmode\" value=\"transparent\">";
		flash += "<param name=\"menu\" value=\"false\">";
		flash += "<embed src=\""+ param4 +"\" quality=high pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" type=\"application/x-shockwave-flash\" width=\"640\" height=\"426\" wmode=\"transparent\" name=\"Tutorial\">";
		flash += "</embed>";
		flash += "</object>";
		document.getElementById("VideoFlash").innerHTML = flash;
	}
	
	document.getElementById("VideoTitle").innerHTML = param2;
	document.getElementById("VideoText").innerHTML = param3;
	
	if (browser == 'Internet Explorer') {
		document.getElementById(param1).style.visibility = "visible";
	} else {
		Effect.Appear(param1);
	}
}
function loadVideoAffiliate(param1, param2, param3, param4) {
	var layerHeight = document.body.scrollHeight;
	var clientHeight = document.body.clientHeight;
	var topPosition = Math.round(((clientHeight / 2) - 254) + document.body.scrollTop);
	document.getElementById(param1).style.top = topPosition;
	if (document.getElementById('instantCallback_Dialog') == undefined) {
		var oDiv = document.createElement("div");
		oDiv.id = "instantCallback_Dialog";
		oDiv.style.height = layerHeight;
		document.body.appendChild(oDiv);
	}
	
	var flash;
	
	if (param4 != '' || param4 != undefined) {
		flash = "<param name=movie value=\""+ param4 +"\">";
		flash += "<param name=quality value=high>";
		flash += "<param name=\"wmode\" value=\"transparent\">";
		flash += "<param name=\"menu\" value=\"false\">";
		flash += "<embed src=\""+ param4 +"\" quality=high pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" type=\"application/x-shockwave-flash\" width=\"640\" height=\"426\" wmode=\"transparent\" name=\"Tutorial\">";
		flash += "</embed>";
		flash += "</object>";
		document.getElementById("VideoFlash").innerHTML = flash;
	}
	
	document.getElementById("VideoTitle").innerHTML = param2;
	document.getElementById("VideoText").innerHTML = param3;
	
	if (browser == 'Internet Explorer') {
		document.getElementById(param1).style.visibility = "visible";
	} else {
		document.getElementById(param1).style.display = "inline";
	}
}
function loadVideoOverlay(param1, param2, param3, param4) {
	if (browser == 'Internet Explorer') {
		var videoPopUpOverlay = '<div id="VideoPopUp" style="position:absolute; width:908px; height:508px; z-index:200; visibility:hidden;">';
	} else {
		var videoPopUpOverlay = '<div id="VideoPopUp" style="position:absolute; width:908px; height:508px; z-index:200; display:none;">';
	}
	videoPopUpOverlay += '<div id="VideoClose"><a href="javascript:closePopUp(\'VideoPopUp\');"><img src="/images/spacer.gif" width="25" height="25" border="0"></a></div>';
	videoPopUpOverlay += '<div id="VideoFlash"></div>';
	videoPopUpOverlay += '<div class="content_videopopup_title" id="VideoTitle" style="text-align:left;"></div>';
	videoPopUpOverlay += '<div class="content_videopopup" id="VideoText" style="text-align:left;"></div>';
	videoPopUpOverlay += '<div id="VideoFeedback"><a href="/feedback.php"><img src="/images/btn_feedback.gif" name="btn_feedback" width="109" height="14" border="0" id="btn_feedback" onMouseOver="MM_swapImage(\'btn_feedback\',\'\',\'/images/btn_feedback_over.gif\',1)" onMouseOut="MM_swapImgRestore()"></a></div>';
	videoPopUpOverlay += '<img src="/images/bkgrd_video_popup.png" width="908" height="508"></div>';
	document.getElementById('VideoOverlay').innerHTML = videoPopUpOverlay;

	var layerHeight = document.body.scrollHeight;
	var clientHeight = document.body.clientHeight;
	var topPosition = Math.round(((clientHeight / 2) - 254) + document.body.scrollTop);
	document.getElementById(param1).style.top = topPosition;
	var oDiv = document.createElement("div");
	oDiv.id = "instantCallback_Dialog";
	oDiv.style.height = layerHeight;
	document.body.appendChild(oDiv);

	var flash;
	
	if (param4 != '' || param4 != undefined) {
		flash = "<param name=movie value=\""+ param4 +"\">";
		flash += "<param name=quality value=high>";
		flash += "<param name=\"wmode\" value=\"transparent\">";
		flash += "<param name=\"menu\" value=\"false\">";
		flash += "<embed src=\""+ param4 +"\" quality=high pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash\" type=\"application/x-shockwave-flash\" width=\"640\" height=\"426\" wmode=\"transparent\" name=\"Tutorial\">";
		flash += "</embed>";
		flash += "</object>";
		document.getElementById("VideoFlash").innerHTML = flash;
	}
	
	document.getElementById("VideoTitle").innerHTML = param2;
	document.getElementById("VideoText").innerHTML = param3;
	
	if (browser == 'Internet Explorer') {
		document.getElementById(param1).style.visibility = "visible";
	} else {
		Effect.Appear(param1);
	}
	correctPNG();
}
function closePopUp(which) {
	removeDialog('instantCallback_Dialog');
	
	if (which == 'VideoPopUp') {
		document.getElementById("VideoFlash").innerHTML = "";
		document.getElementById("VideoTitle").innerHTML = "";
		document.getElementById("VideoText").innerHTML = "";
	}
	
	if (which == 'GalleryPopUp') {
		document.getElementById("GalleryImage").innerHTML = "";
		document.getElementById("GalleryThumbs").innerHTML = "";
		document.getElementById("Title").innerHTML = "";
	}
	if (browser == 'Internet Explorer') {
		document.getElementById(which).style.visibility = "hidden";
	} else {
		document.getElementById(which).style.display = "none";
	}	
}
function instantCallback() {
	scroll(0,0);
	var layerHeight = document.body.scrollHeight;
	var oDiv = document.createElement("div");
	oDiv.id = "instantCallback_Dialog";
	oDiv.style.height = layerHeight;
	document.body.appendChild(oDiv);
	
	var oDiv2 = document.createElement("div");
	oDiv2.id = 'InstantCallbackBackground';
	var domain = location.href.split(":");
	var curDomain1 = location.href.indexOf("http://www.itsmyweb.com");
	var curDomain2 = location.href.indexOf("https://www.itsmyweb.com");
	var curDomain3 = location.href.indexOf("http://dev.itsmyweb.com");
	var curDomain4 = location.href.indexOf("https://dev.itsmyweb.com");
	if (curDomain1 == 0) {
		oDiv2.innerHTML = '<div id="InstantCallbackForm"><div align="center"><br><br><iframe name="instantcallback" src="http://www.itsmyweb.com/instant-callback.php" width="625" height="425" frameborder="no" scrolling="no" allowtransparency="true">Your browser does not support Inline Frames. Please upgrade.</iframe></div></div><div align="center"><img src="/images/bkgrd_instantcallback.png" width="725" height="551"></div>';
	}
	if (curDomain2 == 0) {
		oDiv2.innerHTML = '<div id="InstantCallbackForm"><div align="center"><br><br><iframe name="instantcallback" src="https://www.itsmyweb.com/instant-callback.php" width="625" height="425" frameborder="no" scrolling="no" allowtransparency="true">Your browser does not support Inline Frames. Please upgrade.</iframe></div></div><div align="center"><img src="/images/bkgrd_instantcallback.png" width="725" height="551"></div>';
	}
	if (curDomain3 == 0) {
		oDiv2.innerHTML = '<div id="InstantCallbackForm"><div align="center"><br><br><iframe name="instantcallback" src="http://dev.itsmyweb.com/instant-callback.php" width="625" height="425" frameborder="no" scrolling="no" allowtransparency="true">Your browser does not support Inline Frames. Please upgrade.</iframe></div></div><div align="center"><img src="/images/bkgrd_instantcallback.png" width="725" height="551"></div>';
	}
	if (curDomain4 == 0) {
		oDiv2.innerHTML = '<div id="InstantCallbackForm"><div align="center"><br><br><iframe name="instantcallback" src="https://dev.itsmyweb.com/instant-callback.php" width="625" height="425" frameborder="no" scrolling="no" allowtransparency="true">Your browser does not support Inline Frames. Please upgrade.</iframe></div></div><div align="center"><img src="/images/bkgrd_instantcallback.png" width="725" height="551"></div>';
	}
	document.body.appendChild(oDiv2);
	correctPNG();
	P7AniMagic('InstantCallbackBackground',0,0,30,2,0,0);
}
function removeDialog(which) {
	var dialog = document.getElementById(which);
	dialog.parentNode.removeChild(dialog);
}
function removeInstantCallback() {
	var dialog = document.getElementById('InstantCallbackBackground');
	dialog.parentNode.removeChild(dialog);
	
	var dialog = document.getElementById('instantCallback_Dialog');
	dialog.parentNode.removeChild(dialog);
}
function removeForgotPassword() {
	var dialog = document.getElementById('InstantCallbackBackground');
	dialog.parentNode.removeChild(dialog);
	
	var dialog = document.getElementById('instantCallback_Dialog');
	dialog.parentNode.removeChild(dialog);
}
function forgotPassword() {
	scroll(0,0);
	var oDiv = document.createElement("div");
	oDiv.id = "instantCallback_Dialog";
	document.body.appendChild(oDiv);
	
	var oDiv2 = document.createElement("div");
	oDiv2.id = 'InstantCallbackBackground';
	var domain = location.href.split(":");
	var curDomain1 = location.href.indexOf("https://www.itsmyweb.com");
	var curDomain2 = location.href.indexOf("https://dev.itsmyweb.com");
	if (curDomain1 == 0) {
		oDiv2.innerHTML = '<div id="InstantCallbackForm"><div align="center"><table width="431" height="32" border="0" align="center" cellpadding="0" cellspacing="0"><tr><td>&nbsp;</td></tr></table><iframe name="instantcallback" src="https://www.itsmyweb.com/forgotpassword.php" width="431" height="262" frameborder="no" scrolling="no" allowtransparency="true">Your browser does not support Inline Frames. Please upgrade.</iframe></div></div><div align="center"><img src="/images/bkgrd_requestpassword.png" width="517" height="378"></div>';
	}
	if (curDomain2 == 0) {
		oDiv2.innerHTML = '<div id="InstantCallbackForm"><div align="center"><table width="431" height="32" border="0" align="center" cellpadding="0" cellspacing="0"><tr><td>&nbsp;</td></tr></table><iframe name="instantcallback" src="https://dev.itsmyweb.com/forgotpassword.php" width="431" height="262" frameborder="no" scrolling="no" allowtransparency="true">Your browser does not support Inline Frames. Please upgrade.</iframe></div></div><div align="center"><img src="/images/bkgrd_requestpassword.png" width="517" height="378"></div>';
	}
	document.body.appendChild(oDiv2);
	correctPNG();
	P7AniMagic('InstantCallbackBackground',0,0,30,2,0,0);
}
function formatCurrency(num) {
	num = num.toString().replace(/\$|\,/g,'');
	if(isNaN(num))
	num = "0";
	sign = (num == (num = Math.abs(num)));
	num = Math.floor(num*100+0.50000000001);
	cents = num%100;
	num = Math.floor(num/100).toString();
	if(cents<10)
	cents = "0" + cents;
	for (var i = 0; i < Math.floor((num.length-(1+i))/3); i++)
	num = num.substring(0,num.length-(4*i+3))+','+
	num.substring(num.length-(4*i+3));
	return (((sign)?'':'-') + '$' + num + '.' + cents);
}
function validateForm() {
	var count = "";
	for (i = 0; i < validateFields.length; i++) {
		var fieldToValidate = validateFields[i];
		var fields = fieldToValidate.split('|');
		var fieldname = fields[0];
		var classAdvice = fields[1];
		var className = fields[2];
		var adviceField = "advice-" + fieldname;
		var validateField = document.forms[0].elements[fieldname].value;
		if (validateField == '') { //Field is blank
			document.getElementById(fieldname).className = classAdvice;
			count += "0";
		} else { //Field is NOT blank
			if (fields[3] == undefined) {
				document.getElementById(fieldname).className = className;
				count += "1";
			} else {
				if (fields[3] == "domain") {
					var count;
					var valid = new Array();
					valid[0] = ".com";
					valid[1] = ".net";
					valid[2] = ".biz";
					valid[3] = ".org";
					valid[4] = "www.";
					valid[5] = "http://";
					valid[6] = "http://www";
					for (i = 0; i <= valid.length; i++) {
						if (validateField.indexOf(valid[i]) != -1) {
							document.getElementById(fieldname).className = classAdvice;
							count += "0";						
							break;
						} else {
							document.getElementById(fieldname).className = className;
						}
					}
				}
				if (fields[3] == "checkbox") {
					if (document.forms[0].elements[fieldname].checked) {
						document.getElementById(fields[4]).style.display = "none";
					} else {
						document.getElementById(fields[4]).style.display = "inline";
						count += "0";						
					}
				}
				if (fields[3] == "password") {
					if (document.forms[0].elements['password'].value == document.forms[0].elements['verifypassword'].value) {
						document.getElementById('password').className = className;
						document.getElementById('verifypassword').className = className;
						document.getElementById(fields[4]).style.display = "none";
					} else {
						document.getElementById('password').className = classAdvice;
						document.getElementById('verifypassword').className = classAdvice;
						document.getElementById(fields[4]).style.display = "inline";
						count += "0";						
					}
				}
			}
		}
	}
	var validated = count.indexOf('0');
	if (validated == -1) {
		processData();
	}
}
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_nbGroup(event, grpName) { //v6.0
  var i,img,nbArr,args=MM_nbGroup.arguments;
  if (event == "init" && args.length > 2) {
    if ((img = MM_findObj(args[2])) != null && !img.MM_init) {
      img.MM_init = true; img.MM_up = args[3]; img.MM_dn = img.src;
      if ((nbArr = document[grpName]) == null) nbArr = document[grpName] = new Array();
      nbArr[nbArr.length] = img;
      for (i=4; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
        if (!img.MM_up) img.MM_up = img.src;
        img.src = img.MM_dn = args[i+1];
        nbArr[nbArr.length] = img;
    } }
  } else if (event == "over") {
    document.MM_nbOver = nbArr = new Array();
    for (i=1; i < args.length-1; i+=3) if ((img = MM_findObj(args[i])) != null) {
      if (!img.MM_up) img.MM_up = img.src;
      img.src = (img.MM_dn && args[i+2]) ? args[i+2] : ((args[i+1])? args[i+1] : img.MM_up);
      nbArr[nbArr.length] = img;
    }
  } else if (event == "out" ) {
    for (i=0; i < document.MM_nbOver.length; i++) {
      img = document.MM_nbOver[i]; img.src = (img.MM_dn) ? img.MM_dn : img.MM_up; }
  } else if (event == "down") {
    nbArr = document[grpName];
    if (nbArr)
      for (i=0; i < nbArr.length; i++) { img=nbArr[i]; img.src = img.MM_up; img.MM_dn = 0; }
    document[grpName] = nbArr = new Array();
    for (i=2; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
      if (!img.MM_up) img.MM_up = img.src;
      img.src = img.MM_dn = (args[i+1])? args[i+1] : img.MM_up;
      nbArr[nbArr.length] = img;
  } }
}

function MM_validateForm() { //v4.0
  var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
  for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=MM_findObj(args[i]);
    if (val) { nm=val.name; if ((val=val.value)!="") {
      if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
        if (p<1 || p==(val.length-1)) errors+='- '+nm+' must contain an email address.\n';
      } else if (test!='R') { num = parseFloat(val);
        if (isNaN(val)) errors+='- '+nm+' must contain a number.\n';
        if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
          min=test.substring(8,p); max=test.substring(p+1);
          if (num<min || max<num) errors+='- '+nm+' must contain a number between '+min+' and '+max+'.\n';
    } } } else if (test.charAt(0) == 'R') errors += '- '+nm+' is required.\n'; }
  } if (errors) alert('The following error(s) occurred:\n'+errors);
  document.MM_returnValue = (errors == '');
}
function GP_AdvOpenWindow(theURL,winName,features,popWidth,popHeight,winAlign,ignorelink,alwaysOnTop,autoCloseTime,borderless) { //v2.0
  var leftPos=0,topPos=0,autoCloseTimeoutHandle, ontopIntervalHandle, w = 480, h = 340;  
  if (popWidth > 0) features += (features.length > 0 ? ',' : '') + 'width=' + popWidth;
  if (popHeight > 0) features += (features.length > 0 ? ',' : '') + 'height=' + popHeight;
  if (winAlign && winAlign != "" && popWidth > 0 && popHeight > 0) {
    if (document.all || document.layers || document.getElementById) {w = screen.availWidth; h = screen.availHeight;}
		if (winAlign.indexOf("center") != -1) {topPos = (h-popHeight)/2;leftPos = (w-popWidth)/2;}
		if (winAlign.indexOf("bottom") != -1) topPos = h-popHeight; if (winAlign.indexOf("right") != -1) leftPos = w-popWidth; 
		if (winAlign.indexOf("left") != -1) leftPos = 0; if (winAlign.indexOf("top") != -1) topPos = 0; 						
    features += (features.length > 0 ? ',' : '') + 'top=' + topPos+',left='+leftPos;}
  if (document.all && borderless && borderless != "" && features.indexOf("fullscreen") != -1) features+=",fullscreen=1";
  if (window["popupWindow"] == null) window["popupWindow"] = new Array();
  var wp = popupWindow.length;
  popupWindow[wp] = window.open(theURL,winName,features);
  //if (popupWindow[wp].opener == null) popupWindow[wp].opener = self;  
  if (document.all || document.layers || document.getElementById) {
    if (borderless && borderless != "") {popupWindow[wp].resizeTo(popWidth,popHeight); popupWindow[wp].moveTo(leftPos, topPos);}
    if (alwaysOnTop && alwaysOnTop != "") {
    	ontopIntervalHandle = popupWindow[wp].setInterval("window.focus();", 50);
    	popupWindow[wp].document.body.onload = function() {window.setInterval("window.focus();", 50);}; }
    if (autoCloseTime && autoCloseTime > 0) {
    	popupWindow[wp].document.body.onbeforeunload = function() {
  			if (autoCloseTimeoutHandle) window.clearInterval(autoCloseTimeoutHandle);
    		window.onbeforeunload = null;	}  
   		autoCloseTimeoutHandle = window.setTimeout("popupWindow["+wp+"].close()", autoCloseTime * 1000); }
  	//window.onbeforeunload = function() {for (var i=0;i<popupWindow.length;i++) popupWindow[i].close();};
	}   
  document.MM_returnValue = (ignorelink && ignorelink != "") ? false : true;
}
function YY_checkform() { //v4.71
//copyright (c)1998,2002 Yaromat.com
  var a=YY_checkform.arguments,oo=true,v='',s='',err=false,r,o,at,o1,t,i,j,ma,rx,cd,cm,cy,dte,at;
  for (i=1; i<a.length;i=i+4){
    if (a[i+1].charAt(0)=='#'){r=true; a[i+1]=a[i+1].substring(1);}else{r=false}
    o=MM_findObj(a[i].replace(/\[\d+\]/ig,""));
    o1=MM_findObj(a[i+1].replace(/\[\d+\]/ig,""));
    v=o.value;t=a[i+2];
    if (o.type=='text'||o.type=='password'||o.type=='hidden'){
      if (r&&v.length==0){err=true}
      if (v.length>0)
      if (t==1){ //fromto
        ma=a[i+1].split('_');if(isNaN(v)||v<ma[0]/1||v > ma[1]/1){err=true}
      } else if (t==2){
        rx=new RegExp("^[\\w\.=-]+@[\\w\\.-]+\\.[a-zA-Z]{2,4}$");if(!rx.test(v))err=true;
      } else if (t==3){ // date
        ma=a[i+1].split("#");at=v.match(ma[0]);
        if(at){
          cd=(at[ma[1]])?at[ma[1]]:1;cm=at[ma[2]]-1;cy=at[ma[3]];
          dte=new Date(cy,cm,cd);
          if(dte.getFullYear()!=cy||dte.getDate()!=cd||dte.getMonth()!=cm){err=true};
        }else{err=true}
      } else if (t==4){ // time
        ma=a[i+1].split("#");at=v.match(ma[0]);if(!at){err=true}
      } else if (t==5){ // check this 2
            if(o1.length)o1=o1[a[i+1].replace(/(.*\[)|(\].*)/ig,"")];
            if(!o1.checked){err=true}
      } else if (t==6){ // the same
            if(v!=MM_findObj(a[i+1]).value){err=true}
      }
    } else
    if (!o.type&&o.length>0&&o[0].type=='radio'){
          at = a[i].match(/(.*)\[(\d+)\].*/i);
          o2=(o.length>1)?o[at[2]]:o;
      if (t==1&&o2&&o2.checked&&o1&&o1.value.length/1==0){err=true}
      if (t==2){
        oo=false;
        for(j=0;j<o.length;j++){oo=oo||o[j].checked}
        if(!oo){s+='* '+a[i+3]+'\n'}
      }
    } else if (o.type=='checkbox'){
      if((t==1&&o.checked==false)||(t==2&&o.checked&&o1&&o1.value.length/1==0)){err=true}
    } else if (o.type=='select-one'||o.type=='select-multiple'){
      if(t==1&&o.selectedIndex/1==0){err=true}
    }else if (o.type=='textarea'){
      if(v.length<a[i+1]){err=true}
    }
    if (err){s+='* '+a[i+3]+'\n'; err=false}
  }
  if (s!=''){alert('The required information is incomplete or contains errors:\t\t\t\t\t\n\n'+s)}
  document.MM_returnValue = (s=='');
}
//PNG fix for IE
function correctPNG() // correctly handle PNG transparency in Win IE 5.5 & 6.
{
   var arVersion = navigator.appVersion.split("MSIE")
   var version = parseFloat(arVersion[1])
   if ((version >= 5.5) && (document.body.filters)) 
   {
      for(var i=0; i<document.images.length; i++)
      {
         var img = document.images[i]
         var imgName = img.src.toUpperCase()
         if (imgName.substring(imgName.length-3, imgName.length) == "PNG")
         {
            var imgID = (img.id) ? "id='" + img.id + "' " : ""
            var imgClass = (img.className) ? "class='" + img.className + "' " : ""
            var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' "
            var imgStyle = "display:inline-block;" + img.style.cssText 
            if (img.align == "left") imgStyle = "float:left;" + imgStyle
            if (img.align == "right") imgStyle = "float:right;" + imgStyle
            if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle
            var strNewHTML = "<span " + imgID + imgClass + imgTitle
            + " style=\"" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";"
            + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader"
            + "(src=\'" + img.src + "\', sizingMethod='scale');\"></span>" 
            img.outerHTML = strNewHTML
            i = i-1
         }
      }
   }    
}
function numbersonly(e, decimal) {
	var key;
	var keychar;
	
	if (window.event) {
	   key = window.event.keyCode;
	}
	else if (e) {
	   key = e.which;
	}
	else {
	   return true;
	}
	keychar = String.fromCharCode(key);
	
	if ((key==null) || (key==0) || (key==8) ||  (key==9) || (key==13) || (key==27) ) {
	   return true;
	}
	else if ((("0123456789").indexOf(keychar) > -1)) {
	   return true;
	}
	else if (decimal && (keychar == ".")) { 
	  return true;
	}
	else
	   return false;
}
function P7AniMagic(el,x,y,a,b,c,s) { //v2.9 PVII-Project Seven Development
 var xx,yy,i,g,elo=el,f="",m=false,d="",pa='px';if(document.layers||window.opera){pa='';}
 x=parseInt(x);y=parseInt(y);var t='g.p7Magic=setTimeout("P7AniMagic(\''+elo+'\','; 
 if((g=MM_findObj(el))!=null){d=(document.layers)?g:g.style;}else{return;}
 if(parseInt(s)>0){eval(t+x+','+y+','+a+','+b+','+c+',0)",' + s+')');return;}
 xx=parseInt(d.left);if(isNaN(xx)){if(g.currentStyle){xx=parseInt(g.currentStyle.left);
 }else if(document.defaultView&&document.defaultView.getComputedStyle){
 xx=parseInt(document.defaultView.getComputedStyle(g,"").getPropertyValue("left"));}
 if(isNaN(xx)){xx=0;}}yy=parseInt(d.top);if(isNaN(yy)){if(g.currentStyle){yy=parseInt(g.currentStyle.top);
 }else if(document.defaultView&&document.defaultView.getComputedStyle){
 yy=parseInt(document.defaultView.getComputedStyle(g,"").getPropertyValue("top"));}
 if(isNaN(yy)){yy=0;}}if(c==1){x+=xx;y+=yy;m=true;c=0;}else if(c==2){m=false;
 if(g.p7Magic){clearTimeout(g.p7Magic);}}else{i=parseInt(a);if(g.p7Magic){clearTimeout(g.p7Magic);}
 if(xx<x){xx+=i;m=true;if(xx>x){xx=x;}}if(xx>x){xx-=i;m=true;if(xx<x){xx=x;}}
 if(yy<y){yy+=i;m=true;if(yy>y){yy=y;}}if(yy>y){yy-=i;m=true;if(yy<y){yy=y;}}}
 if(m){d.left=xx+pa;d.top=yy+pa;eval(t+x+','+y+','+a+','+b+','+c+',0)",'+b+')');}
}
function parseURLForParam(fieldName) {
	var str = unescape(document.location.href);
	if ((str == null) || (str == "")) {
		return "";
	} else {
		if (str.indexOf(fieldName) == -1) {
			return "";
		}
		var startString = str.substr(str.indexOf(fieldName) + (fieldName.length + 1));
		var end = (startString.indexOf("&") != -1) ? (startString.indexOf("&")) : startString.length;
		var answer = startString.substr(0,end);
		return answer;
	}
}
//*************************************Browser Detection************************************************

var detect = navigator.userAgent.toLowerCase();
var OS,browser,total,thestring;
var version = 0;

if (checkIt('konqueror'))
{
	browser = "Konqueror";
	OS = "Linux";
}
else if (checkIt('safari')) browser = "Safari"
else if (checkIt('omniweb')) browser = "OmniWeb"
else if (checkIt('opera')) browser = "Opera"
else if (checkIt('webtv')) browser = "WebTV";
else if (checkIt('icab')) browser = "iCab"
else if (checkIt('msie')) browser = "Internet Explorer"
else if (!checkIt('compatible'))
{
	browser = "Netscape Navigator"
	version = detect.charAt(8);
}
else browser = "An unknown browser";

if (!version) version = detect.charAt(place + thestring.length);

if (!OS)
{
	if (checkIt('linux')) OS = "Linux";
	else if (checkIt('x11')) OS = "Unix";
	else if (checkIt('mac')) OS = "Mac"
	else if (checkIt('win')) OS = "Windows"
	else OS = "an unknown operating system";
}

function checkIt(string)
{
	place = detect.indexOf(string) + 1;
	thestring = string;
	return place;
}