//var c2murl = "http://localhost:8080/GTMServices/";
var c2murl = "http://www.vivatext.com/GTMServices/";
//var c2murl = "http://www.globaltelmedia.com:8080/GTMServices/";


/* To display the popup window on clicking the ringtone and response from mobile*/
function ringtone2Mobile2way(price,userid,siteid,path){
	
	var popup = document.getElementById("popup");
	
	var tableStyle = 'font-family:Verdana, Arial, Helvetica, sans-serif; font-size:2px; font-weight:normal; color: #red; padding:5px;';
	var strHtml = '<form action="http://www.globaltelmedia.com:8080/GlobalTelMedia/sendConfirmation" method="post" name="frmContent" id="frmContent" onSubmit="return ringtone2wayForm();">';
	strHtml += '<table width="90%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
	strHtml += '<tr><td>';
	strHtml += '<table width="90%" border="0" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA">';
	strHtml += '<tr>';
	strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspabn="2">';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3">';
	strHtml += '<tr align="center" valign="middle"> ';
	strHtml += '<td colspan="3"><font style="verdana" color="red" size="2"><span id="msg">&nbsp;</span></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td align="right" nowrap>&nbsp;&nbsp;<font style="verdana" color="#000000" size="2">PhoneNumber:</td>';
	strHtml += '<td nowrap><input id="mobile1" name="mobile1" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile2" name="mobile2" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile3" name="mobile3" type="text"  size="4" maxlength="4" /><span><font style="verdana" color="red" size="2">*</font></span></td>';
	strHtml += '<td><input name="assetpath" id="assetpath" value="'+path+'" type="hidden" ></td>';
	strHtml += '<td><input name="price" id="price" value="'+price+'" type="hidden" ><input name="userid" id="userid" value="'+userid+'" type="hidden" ><input name="siteid" id="siteid" value="'+siteid+'" type="hidden" ></font></td>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '<td colspan="2" nowrap><font style="verdana" color="#000000" size="2">Format: (650-527-0869)</font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2"><input type="checkbox" name="chkreply" id="chkreply"><font style="verdana" color="#000000" size="2">$'+(price/100)+' will be charged against your cell phone account with your carrier. If you approve of the charge, please select the check box.</font></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2"><input type="checkbox" name="terms" id="terms"><font style="verdana" color="#000000" size="2">I agree to the terms and conditions.</font></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '<td><input type="submit" value="Send"></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2">&nbsp;<font style="verdana" color="#000000" size="2">Note: You can send only to US phones.</font></td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td></tr></table>';
	strHtml += '</form>';
	
	popup.innerHTML = strHtml;
	popup.style.display="block";
	document.getElementById("mobile1").focus();
}

/* To display the popup window on clicking the 3GP and response from mobile*/
function download3GP2Mobile2way(price,userid,siteid,path){
	
	var popup = document.getElementById("popup");
	
	var tableStyle = 'font-family:Verdana, Arial, Helvetica, sans-serif; font-size:2px; font-weight:normal; color: #red; padding:5px;';
	var strHtml = '<form action="http://www.globaltelmedia.com:8080/GlobalTelMedia/sendConfirmation" method="post" name="frmContent" id="frmContent" onSubmit="return download3GP2wayForm();">';
	strHtml += '<table width="90%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
	strHtml += '<tr><td>';
	strHtml += '<table width="90%" border="0" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA">';
	strHtml += '<tr>';
	strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspabn="2">';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3">';
	strHtml += '<tr align="center" valign="middle"> ';
	strHtml += '<td colspan="3"><font style="verdana" color="red" size="2"><span id="msg">&nbsp;</span></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td align="right" nowrap>&nbsp;&nbsp;<font style="verdana" color="#000000" size="2">PhoneNumber:</td>';
	strHtml += '<td nowrap><input id="mobile1" name="mobile1" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile2" name="mobile2" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile3" name="mobile3" type="text"  size="4" maxlength="4" /><span><font style="verdana" color="red" size="2">*</font></span></td>';
	strHtml += '<td><input name="assetpath" id="assetpath" value="'+path+'" type="hidden" ></td>';
	strHtml += '<td><input name="price" id="price" value="'+price+'" type="hidden" ><input name="userid" id="userid" value="'+userid+'" type="hidden" ><input name="siteid" id="siteid" value="'+siteid+'" type="hidden" ></font></td>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '<td colspan="2" nowrap><font style="verdana" color="#000000" size="2">Format: (650-527-0869)</font></td>';
	strHtml += '</tr>';
	//strHtml += '<tr>';
	//strHtml += '<td colspan="2"><input type="checkbox" name="chkreply" id="chkreply"><font style="verdana" color="#000000" size="2">$'+(price/100)+' will be charged against your cell phone account with your carrier. If you approve of the charge, please select the check box.</font></td>';
	//strHtml += '<td>&nbsp;</td>';
	//strHtml += '</tr>';
	//strHtml += '<tr>';
	//strHtml += '<td colspan="2"><input type="checkbox" name="terms" id="terms"><font style="verdana" color="#000000" size="2">I agree to the terms and conditions.</font></td>';
	//strHtml += '<td>&nbsp;</td>';
	//strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '<td><input type="submit" value="Send"></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2">&nbsp;<font style="verdana" color="#000000" size="2">Note: You can send only to US phones.</font></td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td></tr></table>';
	strHtml += '</form>';
	
	popup.innerHTML = strHtml;
	popup.style.display="block";
	document.getElementById("mobile1").focus();
}


/* To display the popup window on clicking the image */
function click2Mobile(price,userid,siteid,event){
	var content = (window.event) ? window.event.srcElement : event.target;
	var popup = document.getElementById("popup");

	document.getElementById("popup").style.top = (screen.height-350)/2 +'px';
	document.getElementById("popup").style.left = (screen.width-350)/2+'px';

	var tableStyle = 'font-family:Verdana, Arial, Helvetica, sans-serif; font-size:2px; font-weight:normal; color: #red; padding:5px;';
	var strHtml = '<form action="http://www.globaltelmedia.com:8080/GlobalTelMedia/sendConfirmation" method="post" name="frmContent" id="frmContent" onSubmit="return validateForm();">';
	strHtml += '<table width="70%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
	strHtml += '<tr><td>';
	strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA">';
	strHtml += '<tr>';
	strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td><IMG SRC='+content.src+' WIDTH="128" HEIGHT="128" BORDER="0" ALT=""></td>';
	strHtml += '<td>';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3">';
	strHtml += '<tr align="center" valign="middle"> ';
	strHtml += '<td colspan="3"><font style="verdana" color="red" size="2"><span id="msg">&nbsp;</span></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td align="right" nowrap>&nbsp;&nbsp;<font style="verdana" color="#000000" size="2">PhoneNumber:</td>';
	strHtml += '<td nowrap><input id="mobile1" name="mobile1" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile2" name="mobile2" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile3" name="mobile3" type="text"  size="4" maxlength="4" /><span><font style="verdana" color="red" size="2">*</font></span></td>';
	strHtml += '<td><input name="assetpath" id="assetpath" value="'+content.src+'" type="hidden" ></td>';
	strHtml += '<td><input name="price" id="price" value="'+price+'" type="hidden" ><input name="userid" id="userid" value="'+userid+'" type="hidden" ><input name="siteid" id="siteid" value="'+siteid+'" type="hidden" ></font></td>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '<td colspan="2" nowrap><font style="verdana" color="#000000" size="2">Format: (650-527-0869)</font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '<td><input type="submit" value="Send"></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2">&nbsp;<font style="verdana" color="#000000" size="2">Note: You can send only to US phones.</font></td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td></tr></table>';
	strHtml += '</form>';
	
	popup.innerHTML = strHtml;
	popup.style.display="block";
	document.getElementById("mobile1").focus();
}

/* To display the popup window on clicking the image without psms */
function click2MobileFree(userid,siteid,event){
	var content = (window.event) ? window.event.srcElement : event.target;
	var popup = document.getElementById("popup");

	document.getElementById("popup").style.top = (screen.height-350)/2 +'px';
	document.getElementById("popup").style.left = (screen.width-350)/2+'px';

	var tableStyle = 'font-family:Verdana, Arial, Helvetica, sans-serif; font-size:2px; font-weight:normal; color: #red; padding:5px;';
	var strHtml = '<form action="" method="post" name="frmContent" id="frmContent" onSubmit="return validateFreeForm();">';
	strHtml += '<table width="70%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
	strHtml += '<tr><td>';
	strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA">';
	strHtml += '<tr>';
	strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td><IMG SRC='+content.src+' WIDTH="128" HEIGHT="128" BORDER="0" ALT=""></td>';
	strHtml += '<td>';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3">';
	strHtml += '<tr align="center" valign="middle"> ';
	strHtml += '<td colspan="3"><font style="verdana" color="red" size="2"><span id="msg">&nbsp;</span></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td align="right" nowrap>&nbsp;&nbsp;<font style="verdana" color="#000000" size="2">PhoneNumber:</td>';
	strHtml += '<td nowrap><input id="mobile1" name="mobile1" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile2" name="mobile2" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile3" name="mobile3" type="text"  size="4" maxlength="4" /><span><font style="verdana" color="red" size="2">*</font></span></td>';
	strHtml += '<td><input name="assetpath" id="assetpath" value="'+content.src+'" type="hidden" ></td>';
	strHtml += '<td><input name="price" id="price" value="0" type="hidden" ><input name="userid" id="userid" value="'+userid+'" type="hidden" ><input name="siteid" id="siteid" value="'+siteid+'" type="hidden" ></font></td>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '<td colspan="2" nowrap><font style="verdana" color="#000000" size="2">Format: (650-527-0869)</font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '<td><input type="submit" value="Send"></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2">&nbsp;<font style="verdana" color="#000000" size="2">Note: You can send only to US phones.</font></td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td></tr></table>';
	strHtml += '</form>';
	
	popup.innerHTML = strHtml;
	popup.style.display="block";
	document.getElementById("mobile1").focus();
}

/* To display the popup window on clicking the image */
function click2MobileOpt(price,userid,siteid,event){
	var content = (window.event) ? window.event.srcElement : event.target;
	var popup = document.getElementById("popup");

	document.getElementById("popup").style.top = (screen.height-350)/2 +'px';
	document.getElementById("popup").style.left = (screen.width-350)/2+'px';
		
	var tableStyle = 'font-family:Verdana, Arial, Helvetica, sans-serif; font-size:2px; font-weight:normal; color: #red; padding:5px;';
	var strHtml = '<form action="http://www.globaltelmedia.com:8080/GlobalTelMedia/sendConfirmation" method="post" name="frmContent" id="frmContent" onSubmit="return Valclick2MobileOpt();">';
	strHtml += '<table width="70%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
	strHtml += '<tr><td>';
	strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA">';
	strHtml += '<tr>';
	strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td><IMG SRC='+content.src+' WIDTH="128" HEIGHT="128" BORDER="0" ALT=""></td>';
	strHtml += '<td>';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3">';
	strHtml += '<tr align="center" valign="middle"> ';
	strHtml += '<td colspan="3"><font style="verdana" color="red" size="2"><span id="msg">&nbsp;</span></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td align="right" nowrap>&nbsp;&nbsp;<font style="verdana" color="#000000" size="2">PhoneNumber:</td>';
	strHtml += '<td nowrap><input id="mobile1" name="mobile1" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile2" name="mobile2" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile3" name="mobile3" type="text"  size="4" maxlength="4" /><span><font style="verdana" color="red" size="2">*</font></span></td>';
	strHtml += '<td><input name="assetpath" id="assetpath" value="'+content.src+'" type="hidden" ></td>';
	strHtml += '<td><input name="price" id="price" value="'+price+'" type="hidden" ><input name="userid" id="userid" value="'+userid+'" type="hidden" ><input name="siteid" id="siteid" value="'+siteid+'" type="hidden" ></font></td>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '<td colspan="2" nowrap><font style="verdana" color="#000000" size="2">Format: (650-527-0869)</font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2"><input type="checkbox" name="chkreply" id="chkreply"><font style="verdana" color="#000000" size="2">$'+(price/100)+' will be charged against your cell phone account with your carrier. If you approve of the charge, please select the check box.</font></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2"><input type="checkbox" name="terms" id="terms"><font style="verdana" color="#000000" size="2">I agree to the terms and conditions.</font></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '<td><input type="submit" value="Send"></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2">&nbsp;<font style="verdana" color="#000000" size="2">Note: You can send only to US phones.</font></td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td></tr></table>';
	strHtml += '</form>';
	
	popup.innerHTML = strHtml;
	popup.style.display="block";
	document.getElementById("mobile1").focus();
}

/* To display the popup window on clicking the image and response from mobile*/
function click2Mobile2way(price,userid,siteid,event){
	var content = (window.event) ? window.event.srcElement : event.target;
	var popup = document.getElementById("popup");

	document.getElementById("popup").style.top = (screen.height-350)/2 +'px';
	document.getElementById("popup").style.left = (screen.width-350)/2+'px';
	
	var tableStyle = 'font-family:Verdana, Arial, Helvetica, sans-serif; font-size:2px; font-weight:normal; color: #red; padding:5px;';
	var strHtml = '<form action="http://www.globaltelmedia.com:8080/GlobalTelMedia/sendConfirmation" method="post" name="frmContent" id="frmContent" onSubmit="return validate2wayForm();">';
	strHtml += '<table width="70%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
	strHtml += '<tr><td>';
	strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA">';
	strHtml += '<tr>';
	strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td><IMG SRC='+content.src+' WIDTH="128" HEIGHT="128" BORDER="0" ALT=""></td>';
	strHtml += '<td>';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3">';
	strHtml += '<tr align="center" valign="middle"> ';
	strHtml += '<td colspan="3"><font style="verdana" color="red" size="2"><span id="msg">&nbsp;</span></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td align="right" nowrap>&nbsp;&nbsp;<font style="verdana" color="#000000" size="2">PhoneNumber:</td>';
	strHtml += '<td nowrap><input id="mobile1" name="mobile1" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile2" name="mobile2" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile3" name="mobile3" type="text"  size="4" maxlength="4" /><span><font style="verdana" color="red" size="2">*</font></span></td>';
	strHtml += '<td><input name="assetpath" id="assetpath" value="'+content.src+'" type="hidden" ></td>';
	strHtml += '<td><input name="price" id="price" value="'+price+'" type="hidden" ><input name="userid" id="userid" value="'+userid+'" type="hidden" ><input name="siteid" id="siteid" value="'+siteid+'" type="hidden" ></font></td>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '<td colspan="2" nowrap><font style="verdana" color="#000000" size="2">Format: (650-527-0869)</font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2"><input type="checkbox" name="chkreply" id="chkreply"><font style="verdana" color="#000000" size="2">$'+(price/100)+' will be charged against your cell phone account with your carrier. If you approve of the charge, please select the check box.</font></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2"><input type="checkbox" name="terms" id="terms"><font style="verdana" color="#000000" size="2">I agree to the terms and conditions.</font></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '<td><input type="submit" value="Send"></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2">&nbsp;<font style="verdana" color="#000000" size="2">Note: You can send only to US phones.</font></td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td></tr></table>';
	strHtml += '</form>';
	
	popup.innerHTML = strHtml;
	popup.style.display="block";
	document.getElementById("mobile1").focus();
}


/* Javascript filed validations */
function validatePhoneNumber(txtObj){
	var msg = document.getElementById("msg");
		if((txtObj.value.length < txtObj.maxLength) || (!ValidCharSet(txtObj,"0123456789"))){
			msg.innerHTML =  "Please enter a  valid mobile number.";
			txtObj.focus();
			return false;
		}
		return true;
	}
	function ValidCharSet(objText,charset){
		str=objText.value;
		if(str.length <= 0){
		return true;
		}
		
		var result = true;
		for (var i=0;i<str.length;i++){
					if (charset.indexOf(str.substr(i,1))<0){
						result = false;
						break;
					}
		}
		return result;
	}
	function jumpToNextTxtObj(txtObj,oEvent){
		var evt = (oEvent)?oEvent:window.event;
		if((evt.keyCode == 9) || (evt.keyCode == 16)) return;
		if(txtObj.value.length>= txtObj.maxLength){
			txtObj.nextSibling.focus();
		}
	}
	function validateMobile(){
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
		
		
				if(!validatePhoneNumber(mobile1)){
					return false;
				}else if(!validatePhoneNumber(mobile2)){
					return false;

				}else if(!validatePhoneNumber(mobile3)){
					return false;
				}			
		
		return true;
	
	}
function validateForm() {
		var msg = document.getElementById("msg");
		if(!validateMobile()){
		msg.innerHTML =  "Please enter a  valid phone number.";
		return false;
        }
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
        var userid = document.getElementById("userid");
        var siteid = document.getElementById("siteid");
        
       
		//call json here...
			sendRequest(c2murl+"sendConfirmation?mobileno="+mobile1.value+mobile2.value+mobile3.value+"&assetpath="+document.frmContent.assetpath.value+"&price="+document.frmContent.price.value+"&userid="+userid.value+"&siteid="+siteid.value+"&output=json&callback=handleResults");
		
		return false;
		
}


function validateFreeForm() {
		var msg = document.getElementById("msg");
		if(!validateMobile()){
		msg.innerHTML =  "Please enter a  valid mobile number.";
		return false;
        }
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
        var userid = document.getElementById("userid");
        var siteid = document.getElementById("siteid");
        
		
				//call json here...
				sendRequest(c2murl+"sendWapPush?mobileno="+mobile1.value+mobile2.value+mobile3.value+"&assetpath="+document.frmContent.assetpath.value+"&price="+document.frmContent.price.value+"&userid="+userid.value+"&siteid="+siteid.value+"&chkvalue=true&output=json&callback=handleResults");
					
		return false;
		
}



function Valclick2MobileOpt() {
		var msg = document.getElementById("msg");
		if(!validateMobile()){
		msg.innerHTML =  "Please enter a  valid phone number.";
		return false;
        }
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
        var userid = document.getElementById("userid");
        var siteid = document.getElementById("siteid");
        var chkid = document.getElementById("chkreply");
        var terms = document.getElementById("terms");
		
		if(terms.checked){
		//call json here...
			sendRequest(c2murl+"sendConfirmation?mobileno="+mobile1.value+mobile2.value+mobile3.value+"&assetpath="+document.frmContent.assetpath.value+"&price="+document.frmContent.price.value+"&userid="+userid.value+"&siteid="+siteid.value+"&chkvalue="+chkid.checked+"&output=json&callback=handleResults");
		}else{
			msg.innerHTML =  "You need to accept the terms and conditions to send.";
		}
		return false;
		
}

function validate2wayForm() {
		var msg = document.getElementById("msg");
		if(!validateMobile()){
		msg.innerHTML =  "Please enter a  valid phone number.";
		return false;
        }
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
        var userid = document.getElementById("userid");
        var siteid = document.getElementById("siteid");
        var chkid = document.getElementById("chkreply");
		var terms = document.getElementById("terms");

		if(chkid.checked){
			if(terms.checked){
				//call json here...
				sendRequest(c2murl+"sendConfirmation?mobileno="+mobile1.value+mobile2.value+mobile3.value+"&assetpath="+document.frmContent.assetpath.value+"&price="+document.frmContent.price.value+"&userid="+userid.value+"&siteid="+siteid.value+"&chkvalue="+chkid.checked+"&output=json&callback=handleResults");
			}else{
				msg.innerHTML =  "You need to accept the terms and conditions to send.";
			}
		}else{
			msg.innerHTML =  "Please select the check box for your confirmation";
		}
					
		return false;
		
}

function Send(price, userid, siteid, imgpath) {
		var msg = document.getElementById("msg");
		if(!validateMobile()){
		msg.innerHTML =  "Please enter a  valid phone number.";
		return false;
        }
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
       	
			//call json here...
				sendRequest(c2murl+"sendConfirmation?mobileno="+mobile1.value+mobile2.value+mobile3.value+"&assetpath="+escape(imgpath)+"&price="+price+"&userid="+userid+"&siteid="+siteid+"&chkvalue=true&output=json&callback=handleResults");
					
		
}


function ringtone2wayForm() {
		var msg = document.getElementById("msg");
		if(!validateMobile()){
		msg.innerHTML =  "Please enter a  valid phone number.";
		return false;
        }
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
        var userid = document.getElementById("userid");
        var siteid = document.getElementById("siteid");
        var chkid = document.getElementById("chkreply");
		var terms = document.getElementById("terms");

		if(chkid.checked){
			if(terms.checked){
				//call json here...
				sendRequest(c2murl+"sendConfirmation?mobileno="+mobile1.value+mobile2.value+mobile3.value+"&assetpath="+document.frmContent.assetpath.value+"&price="+document.frmContent.price.value+"&userid="+userid.value+"&siteid="+siteid.value+"&chkvalue="+chkid.checked+"&output=json&callback=handleResults");
			}else{
				msg.innerHTML =  "You need to accept the terms and conditions to send.";
			}
		}else{
			msg.innerHTML =  "Please select the check box for your confirmation";
		}
					
		return false;
		
}

function download3GP2wayForm() {
		var msg = document.getElementById("msg");
		if(!validateMobile()){
		msg.innerHTML =  "Please enter a  valid phone number.";
		return false;
        }
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
       	 var userid = document.getElementById("userid");
       	 var siteid = document.getElementById("siteid");
        
			//call json here...
				sendRequest(c2murl+"sendConfirmation?mobileno="+mobile1.value+mobile2.value+mobile3.value+"&assetpath="+document.frmContent.assetpath.value+"&price="+document.frmContent.price.value+"&userid="+userid.value+"&siteid="+siteid.value+"&chkvalue=true&output=json&callback=handleResults");
					
		return false;
		
}


/* To validate a given mobile number */
function ValidCharSet(objText,charset){
	str=objText.value;
	if(str.length <= 0){
	return true;
	}
	var result = true;
	for (var i=0;i<str.length;i++){
		if (charset.indexOf(str.substr(i,1))<0){
					result = false;
					objText.focus();
					objText.select();
					break;
		}
	}
	return result;
}

	
/* To show the popup window to enter the confirmation code */
	function confirmCode(code, mobileno, assetpath, price, userid, siteid){
		
		var popup = document.getElementById("popup");
	       document.getElementById("popup").style.top = (screen.height-350)/2 +'px';
	       document.getElementById("popup").style.left = (screen.width-350)/2+'px';
		popup.innerHTML = "";
		var strHtml = '<form action="http://www.globaltelmedia.com:8080/GTMServices/click2Mobile" method="post" name="frmContent" id="frmContent" onSubmit="return sendContent();">';
		strHtml += '<table width="70%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
		strHtml += '<tr><td>';
		strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" class="userForm" bgcolor="#EAEAEA">';
		strHtml += '<tr>';
		strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
		strHtml += '</tr>';
		strHtml += '<tr>';
		strHtml += '<td><IMG SRC='+assetpath+' WIDTH="128" HEIGHT="128" BORDER="0" ALT=""></td>';
		strHtml += '<td>';
		strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" class="userForm" bgcolor="#EAEAEA">';
		strHtml += '<tr><td><font style="verdana" color="#000000" size="2">$'+(price/100)+' will be charged against your cell phone account with your carrier. If you approve of the charge, please enter the transaction code which has been dispatched to your cell phone.</font></td></tr>';
		strHtml += '<tr align="center" valign="middle"> ';
		strHtml += '<td><font style="verdana" color="red" size="2"><span id="msg" class="msgFail">&nbsp;</span></font></td>';
		strHtml += '</tr>';
		strHtml += '<tr>';
		strHtml += '<td nowrap valign="center"><font style="verdana" color="#000000" size="2">Enter the confiramtion code: <input name="smscode" id="smscode" type="text"></font>';
		strHtml += '<input name="code" id="code" type="hidden" value="'+code+'" >';
		strHtml += '<input name="mobileno" id="mobileno" type="hidden" value="'+mobileno+'" >';
		strHtml += '<input name="assetpath" id="assetpath" type="hidden" value="'+assetpath+'" >';
		strHtml += '<input name="price" id="price" type="hidden" value="'+price+'" >';
		strHtml += '<input name="userid" id="userid" type="hidden" value="'+userid+'" >';
		strHtml += '<input name="userid" id="siteid" type="hidden" value="'+siteid+'" >';
		strHtml += '<span><font style="verdana" color="red" size="2">*</font></span></td>';
		strHtml += '</tr>';
		strHtml += '<tr>';
		strHtml += '<td align="center" colspan="2"><input type="submit" value="Send"></td>';
		strHtml += '</tr>';
		strHtml += '</table>';
		strHtml += '</td>';
		strHtml += '</tr>';
		strHtml += '<tr>';
		strHtml += '<td align="right" colspan="2">&nbsp;</td>';
		strHtml += '</tr>';
		strHtml += '</table>';
		strHtml += '</td></tr></table>';
		strHtml += '</font>';
		strHtml += '</form>';

		popup.innerHTML = strHtml;
	}

	/* To show the popup window to enter the confirmation code wihtout psms */
	function confirmCodeFree(code, mobileno, assetpath, price, userid, siteid){
		
		var popup = document.getElementById("popup");
	       document.getElementById("popup").style.top = (screen.height-350)/2 +'px';
	       document.getElementById("popup").style.left = (screen.width-350)/2+'px';
		popup.innerHTML = "";
		var strHtml = '<form action="http://www.globaltelmedia.com:8080/GTMServices/click2Mobile" method="post" name="frmContent" id="frmContent" onSubmit="return sendContent();">';
		strHtml += '<table width="70%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
		strHtml += '<tr><td>';
		strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" class="userForm" bgcolor="#EAEAEA">';
		strHtml += '<tr>';
		strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
		strHtml += '</tr>';
		strHtml += '<tr>';
		strHtml += '<td><IMG SRC='+assetpath+' WIDTH="128" HEIGHT="128" BORDER="0" ALT=""></td>';
		strHtml += '<td>';
		strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" class="userForm" bgcolor="#EAEAEA">';
		//strHtml += '<tr><td><font style="verdana" color="#000000" size="2">$'+(price/100)+' will be charged against your cell phone account with your carrier. If you approve of the charge, please enter the transaction code which has been dispatched to your cell phone.</font></td></tr>';
		strHtml += '<tr align="center" valign="middle"> ';
		strHtml += '<td><font style="verdana" color="red" size="2"><span id="msg" class="msgFail">&nbsp;</span></font></td>';
		strHtml += '</tr>';
		strHtml += '<tr>';
		strHtml += '<td nowrap valign="center"><font style="verdana" color="#000000" size="2">Enter the confiramtion code: <input name="smscode" id="smscode" type="text"></font>';
		strHtml += '<input name="code" id="code" type="hidden" value="'+code+'" >';
		strHtml += '<input name="mobileno" id="mobileno" type="hidden" value="'+mobileno+'" >';
		strHtml += '<input name="assetpath" id="assetpath" type="hidden" value="'+assetpath+'" >';
		strHtml += '<input name="price" id="price" type="hidden" value="'+price+'" >';
		strHtml += '<input name="userid" id="userid" type="hidden" value="'+userid+'" >';
		strHtml += '<input name="userid" id="siteid" type="hidden" value="'+siteid+'" >';
		strHtml += '<span><font style="verdana" color="red" size="2">*</font></span></td>';
		strHtml += '</tr>';
		strHtml += '<tr>';
		strHtml += '<td align="center" colspan="2"><input type="submit" value="Send"></td>';
		strHtml += '</tr>';
		strHtml += '</table>';
		strHtml += '</td>';
		strHtml += '</tr>';
		strHtml += '<tr>';
		strHtml += '<td align="right" colspan="2">&nbsp;</td>';
		strHtml += '</tr>';
		strHtml += '</table>';
		strHtml += '</td></tr></table>';
		strHtml += '</font>';
		strHtml += '</form>';

		popup.innerHTML = strHtml;
	}


	/* To send content to a given number on confirmation */
	function sendContent(){
		var smscode = document.getElementById("smscode");
		var code = document.getElementById("code");
		var mobileno = document.getElementById("mobileno");
		var assetpath = document.getElementById("assetpath");
		var price = document.getElementById("price");
		var msg = document.getElementById("msg");
		var userid = document.getElementById("userid");
		var siteid = document.getElementById("siteid");
		if(smscode.value == ""){
			msg.innerHTML = "Please enter the code sent to your mobile.";
		}
		else if(smscode.value == code.value){
			//call json here...
				sendRequest(c2murl+"click2Mobile?mobileno="+mobileno.value+"&assetpath="+assetpath.value+"&price="+price.value+"&userid="+userid.value+"&siteid="+siteid.value+"&output=json&callback=statusResults");
				
		}else{
			msg.innerHTML = "Invalid Code! Please enter the code sent to your mobile.";
		}
		return false;
	}

	function closeMe(){
		var popup = document.getElementById("popup");
		popup.innerHTML = "";
		popup.style.display="none";
	}
	
/* To send request to the server using JSON */	
function sendRequest(url)
{
	var headTag = document.getElementsByTagName("head").item(0);
	var scriptTag = document.createElement("script");
	scriptTag.src = url;
	headTag.appendChild( scriptTag );
}

/* To handle validated results from server */
/* function handleResults( resultsObj )
{
	var msg = document.getElementById("msg");
	if(resultsObj.ResultSet.status == "true"){
		confirmCode(resultsObj.ResultSet.code, resultsObj.ResultSet.mobileno, resultsObj.ResultSet.assetpath, resultsObj.ResultSet.price, resultsObj.ResultSet.userid, resultsObj.ResultSet.siteid);
	}else
	if(resultsObj.ResultSet.status == "success"){
		msg.innerHTML = "Content Sent Successfully";
	}
	else
		msg.innerHTML = "Invalid phone Number!";
	
}*/

/* To handle validated results from server */
function handleResults( resultsObj )
{
	//alert("price:"+resultsObj.ResultSet.price);
	var msg = document.getElementById("msg");
	if(resultsObj.ResultSet.status == "true"){
		if(resultsObj.ResultSet.price == ""){
			confirmCodeFree(resultsObj.ResultSet.code, resultsObj.ResultSet.mobileno, resultsObj.ResultSet.assetpath, resultsObj.ResultSet.price, resultsObj.ResultSet.userid, resultsObj.ResultSet.siteid);
		}else{
			confirmCode(resultsObj.ResultSet.code, resultsObj.ResultSet.mobileno, resultsObj.ResultSet.assetpath, resultsObj.ResultSet.price, resultsObj.ResultSet.userid, resultsObj.ResultSet.siteid);
		}
	}else
	if(resultsObj.ResultSet.status == "success"){
		msg.innerHTML = "Message Sent Successfully";
	}
	else
		msg.innerHTML = "Invalid Mobile Number!";
	
}

/* To get the status of the delivery */
function statusResults( resultsObj ){
	var msg = document.getElementById("msg");
	if(resultsObj.ResultSet.status == "true"){
		msg.innerHTML = "Content sent successfully!";
	}
	else
		msg.innerHTML = "Content Delivery Failed!";
}



/* To display the popup window on clicking the image for free wapPush */
function c2MFreeWapPush(event){
	var content = (window.event) ? window.event.srcElement : event.target;
	var popup = document.getElementById("popup");

	document.getElementById("popup").style.top = (screen.height-350)/2 +'px';
	document.getElementById("popup").style.left = (screen.width-350)/2+'px';

	var tableStyle = 'font-family:Verdana, Arial, Helvetica, sans-serif; font-size:2px; font-weight:normal; color: #red; padding:5px;';
	var strHtml = '<form action="" method="post" name="frmContent" id="frmContent" onSubmit="return validateFreeWapPush();">';
	strHtml += '<table width="70%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
	strHtml += '<tr><td>';
	strHtml += '<table width="70%" border="0" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA">';
	strHtml += '<tr>';
	strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td><IMG SRC='+content.src+' WIDTH="128" HEIGHT="128" BORDER="0" ALT=""></td>';
	strHtml += '<td>';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3">';
	strHtml += '<tr align="center" valign="middle"> ';
	strHtml += '<td colspan="3"><font style="verdana" color="red" size="2"><span id="msg">&nbsp;</span></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td align="right" nowrap>&nbsp;&nbsp;<font style="verdana" color="#000000" size="2">PhoneNumber:</td>';
	strHtml += '<td nowrap><input id="mobile1" name="mobile1" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile2" name="mobile2" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile3" name="mobile3" type="text"  size="4" maxlength="4" /><span><font style="verdana" color="red" size="2">*</font></span></td>';
	strHtml += '<td><input name="assetpath" id="assetpath" value="'+content.src+'" type="hidden" ></td>';
	strHtml += '<td><input name="price" id="price" value="0" type="hidden" ><input name="userid" id="userid" value="" type="hidden" ><input name="siteid" id="siteid" value="" type="hidden" ></font></td>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '<td colspan="2" nowrap><font style="verdana" color="#000000" size="2">Format: (650-527-0869)</font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '<td><input type="submit" value="Send"></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td colspan="2">&nbsp;<font style="verdana" color="#000000" size="2">Note: You can send only to US phones.</font></td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td></tr></table>';
	strHtml += '</form>';
	
	popup.innerHTML = strHtml;
	popup.style.display="block";
	document.getElementById("mobile1").focus();
}

function validateFreeWapPush() {
		var msg = document.getElementById("msg");
		if(!validateMobile()){
		msg.innerHTML =  "Please enter a  valid mobile number.";
		return false;
        }
		var mobile1 = document.getElementById("mobile1");
		var mobile2 = document.getElementById("mobile2");
		var mobile3 = document.getElementById("mobile3");
        var userid = document.getElementById("userid");
        var siteid = document.getElementById("siteid");
        
		
				//call json here...
				sendRequest(c2murl+"sendWapPush?mobileno="+mobile1.value+mobile2.value+mobile3.value+"&assetpath="+document.frmContent.assetpath.value+"&price="+document.frmContent.price.value+"&userid="+userid.value+"&siteid="+siteid.value+"&chkvalue=true&output=json&callback=handleResults");
					
		return false;
		
}


/* To display the popup window on clicking the link without psms */
function ringtone2MobileFree(userid,siteid,path){
	//var content = (window.event) ? window.event.srcElement : event.target;
	var popup = document.getElementById("popup");

	document.getElementById("popup").style.top = (screen.height-350)/2 +'px';
	document.getElementById("popup").style.left = (screen.width-350)/2+'px';

	var tableStyle = 'font-family:Verdana, Arial, Helvetica, sans-serif; font-size:2px; font-weight:normal; color: #red; padding:5px;';
	var strHtml = '<form action="" method="post" name="frmContent" id="frmContent" onSubmit="return validateFreeForm();">';
	strHtml += '<table width="70%" border="1" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA" bordercolor="#4e86c4">';
	strHtml += '<tr><td>';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3" bgcolor="#EAEAEA">';
	strHtml += '<tr>';
	strHtml += '<td align="right" colspan="2"><font style="verdana" color="#000000" size="2"><a href="javascript:closeMe()">X</a></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	//strHtml += '<td><IMG SRC='+content.src+' WIDTH="128" HEIGHT="128" BORDER="0" ALT=""></td>';
	strHtml += '<td colspan="2">';
	strHtml += '<table width="100%" border="0" cellspacing="0" cellpadding="3">';
	strHtml += '<tr align="center" valign="middle"> ';
	strHtml += '<td colspan="3"><font style="verdana" color="red" size="2"><span id="msg">&nbsp;</span></font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td align="right" nowrap>&nbsp;&nbsp;<font style="verdana" color="#000000" size="2">PhoneNumber:</td>';
	strHtml += '<td nowrap><input id="mobile1" name="mobile1" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile2" name="mobile2" type="text" size="3" maxlength="3" onkeyup="jumpToNextTxtObj(this,event)" style="margin-right:5px;" /><input id="mobile3" name="mobile3" type="text"  size="4" maxlength="4" /><span><font style="verdana" color="red" size="2">*</font></span></td>';
	strHtml += '<td><input name="assetpath" id="assetpath" value="'+path+'" type="hidden" ></td>';
	strHtml += '<td><input name="price" id="price" value="0" type="hidden" ><input name="userid" id="userid" value="'+userid+'" type="hidden" ><input name="siteid" id="siteid" value="'+siteid+'" type="hidden" ></font></td>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += ' <td>&nbsp;</td>';
	strHtml += '<td colspan="2" nowrap><font style="verdana" color="#000000" size="2">Format: (650-527-0869)</font></td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '<td><input type="submit" value="Send"></td>';
	strHtml += '<td>&nbsp;</td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td>';
	strHtml += '</tr>';
	strHtml += '<tr>';
       strHtml += '<td colspan="2">&nbsp;<font style="verdana" color="#000000" size="2">Note: You can send only to US phones. Download of this product requires the use of Wireless Application Protocol (WAP).  Not all mobile cellular networks or mobile cellular phones support WAP.  Please check with your wireless carrier to determine if your network and your phone support WAP.</font></td>';
	strHtml += '</tr>';
	strHtml += '</table>';
	strHtml += '</td></tr></table>';
	strHtml += '</form>';
	
	popup.innerHTML = strHtml;
	popup.style.display="block";
	document.getElementById("mobile1").focus();
}