
	function mediacns(pagename){
		mediacns_window=window.open(pagename,'mediacns_window','toolbar=no,location=no,borders=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,left=0,top=0,width=600,height=400');
	}


	function test(obj,msg) {
		  var regex = /^[a-zA-Z0-9._-]+@([a-zA-Z0-9.-]+\.)+[a-zA-Z0-9.-]{2,4}$/;
		  if (regex.test(obj.value))
		  {
			return true;
		  }
		  else{
			alert(msg);
			obj.focus();
			return false;
		  }
		}
	function checkint(obj,msg)
	{
	 if(isNaN(obj.value))
	 {
	  alert(msg);
	  obj.focus();
	  return false;
	 }
	}
	function checkempty(obj,msg)
	{
	 if(obj.value=="")
	 {
	  alert(msg);
	  obj.focus();
	  return false;
	 }
	}
	
	function checkequal(obj,obj1,msg)
	{
	 if(obj.value!==obj1.value)
	 {
	  alert(msg);
	  obj.focus();
	  return false;
	 }
	}


	function checkboxcheck(obj,msg)
	{
	 if(!obj.checked)
	 {
	  alert(msg);
	  obj.focus();
	  return false;
	 }
	}

	function restrictemail(obj,msg)
	{
	var hotmailobj = obj.value.match("hotmail.com");
	var yahooobj = obj.value.match("yahoo.com");
	var gmailobj = obj.value.match("gmail.com");
		
	if(hotmailobj || yahooobj || gmailobj)
	 {
	  alert(msg);
	  obj.focus();
	  return false;
	 }
	}


function checkemptysearch(obj,msg)
	{
	 if(obj.value<3)
	 {
	  alert(msg);
	  obj.focus();
	  return false;
	 }
	}


	function checkqForm(scode)
	
	{
		var scode;
		if (checkempty(document.qform.your_name,"Please enter your name")==false) return false;

		if (test(document.qform.email,"Please enter a valid email address")==false) return false;
		if (checkempty(document.qform.phone,"Please enter your phone number")==false) return false;
if (checkempty(document.qform.scode,"Please enter anti-spam code")==false) return false;	
		
		if(document.qform.scode.value!=scode){
			alert("Please enter correct answer for anti-spam code");
			return false;
			}
		
return true;
	}
	
	function checkForm()
	{
		if (checkempty(document.con_form.name,"Qualikom Security System Found the following Error\n Please Enter Your Name")==false) return false;
		if (checkempty(document.con_form.country,"Qualikom Security System Found the following Error\nPlease Enter Your Country")==false) return false;
		if (checkempty(document.con_form.city,"Qualikom Security System Found the following Error\nPlease Enter Your City ")==false) return false;
		if (checkempty(document.con_form.tel,"Qualikom Security System Found the following Error\nPlease Enter Your Telephone No.")==false) return false;
		if (test(document.con_form.email,"Qualikom Security System Found the following Error\nPlease Enter a Valid Email Address")==false) return false;
		if (checkempty(document.con_form.scode,"Qualikom Security System Found the following Error\nPlease Enter displayed Security Code")==false) return false;	
		
return true;
	}

	function checkdomregForm()
	{
		if (checkempty(document.con_form.name,"Qualikom Security System Found the following Error\n Please Enter Your Name")==false) return false;
		if (checkempty(document.con_form.country,"Qualikom Security System Found the following Error\nPlease Enter Your Country")==false) return false;
		if (checkempty(document.con_form.city,"Qualikom Security System Found the following Error\nPlease Enter Your City ")==false) return false;
		if (checkempty(document.con_form.tel,"Qualikom Security System Found the following Error\nPlease Enter Your Telephone No.")==false) return false;
		if (test(document.con_form.email,"Qualikom Security System Found the following Error\nPlease Enter a Valid Email Address")==false) return false;
		if (checkempty(document.con_form.scode,"Qualikom Security System Found the following Error\nPlease Enter displayed Security Code")==false) return false;	

		if (checkboxcheck(document.con_form.check1,"You Must be agreed with Terms of Services & Privacy Policy to Proceed Next")==false) return false;	
		
return true;
	}

	function checksupportForm()
	{
		if (checkempty(document.support_form.name,"Qualikom Security System Found the following Error\n Please Enter Your Name")==false) return false;
		if (checkempty(document.support_form.country,"Qualikom Security System Found the following Error\n Please Enter Your Country")==false) return false;
		if (checkempty(document.support_form.city,"Qualikom Security System Found the following Error\n Please Enter Your City ")==false) return false;
		if (checkempty(document.support_form.tel,"Qualikom Security System Found the following Error\n Please Enter Your Telephone No.")==false) return false;
		if (test(document.support_form.email,"Qualikom Security System Found the following Error\n Please Enter a Valid Email Address")==false) return false;
		if (checkempty(document.support_form.scode,"Qualikom Security System Found the following Error\nPlease Enter displayed Security Code")==false) return false;	
		return true;
	}



function check_search_Form()
	{
		if (checkempty(document.search_form.txtsearch,"Qualikom Security System Found the following Error\n Please Enter something to Search")==false) return false;

		return true;
	}



//------------------------------------
//------------------------------------

	function checkinvestorsForm()
	{
		if (checkempty(document.con_form.name,"Qualikom Security System Found the following Error\n Please Enter Your Name")==false) return false;
		if (checkempty(document.con_form.country,"Qualikom Security System Found the following Error\n Please Enter Your Country")==false) return false;
		if (checkempty(document.con_form.city,"Qualikom Security System Found the following Error\n Please Enter Your City ")==false) return false;
		if (checkempty(document.con_form.tel,"Qualikom Security System Found the following Error\n Please Enter Your Telephone No.")==false) return false;
		if (test(document.con_form.email,"Qualikom Security System Found the following Error\n Please Enter a Valid Email Address")==false) return false;
		if (restrictemail(document.con_form.email,"Qualikom Security System\n Found that you have entered hotmail.com OR yahoo.com OR gmail.com's Email Address \n We are sorry that Free Email Services Address Not allowed\n Please Enter Your Own Domain's Email Address")==false) return false;		
if (checkempty(document.con_form.scode,"Qualikom Security System Found the following Error\nPlease Enter displayed Security Code")==false) return false;	

return true;
	}




	function checkloginForm()
	{

		if (checkempty(document.login_form.username,"Qualikom Security System Found the following Error\n Please Enter User ID")==false) return false;
	if (checkempty(document.login_form.userpass,"Qualikom Security System Found the following Error\n Please Enter Password")==false) return false;

if (checkempty(document.login_form.scode,"Qualikom Security System Found the following Error\nPlease Enter displayed Security Code")==false) return false;	

	
return true;
	}



	function checksignupForm()
	{

		if (checkempty(document.signup_form.username,"Qualikom Security System Found the following Error\n Please Enter User ID")==false) return false;
	if (checkempty(document.signup_form.userpass,"Qualikom Security System Found the following Error\n Please Enter Password")==false) return false;
	if (checkempty(document.signup_form.userpass1,"Qualikom Security System Found the following Error\n Please Re-enter Password")==false) return false;	
if (checkempty(document.signup_form.fullname,"Qualikom Security System Found the following Error\n Please Enter Your Full Name")==false) return false;
		if (checkempty(document.signup_form.country,"Qualikom Security System Found the following Error\n Please Enter Your Country")==false) return false;
		if (checkempty(document.signup_form.city,"Qualikom Security System Found the following Error\n Please Enter Your City ")==false) return false;
		if (checkempty(document.signup_form.tel,"Qualikom Security System Found the following Error\n Please Enter Your Telephone No.")==false) return false;
		if (test(document.signup_form.email,"Qualikom Security System Found the following Error\n Please Enter a Valid Email Address")==false) return false;


if (checkempty(document.signup_form.scode,"Qualikom Security System Found the following Error\nPlease Enter displayed Security Code")==false) return false;	

	if (checkequal(document.signup_form.userpass,document.signup_form.userpass1,"Qualikom Security System Found the following Error\n Both Passwords didn't match")==false) return false;
	
if (checkboxcheck(document.signup_form.check1,"You Must be agreed with Terms of Services & Privacy Policy to Proceed Next")==false) return false;

return true;
	}


//--------------------------------------
//--------------------------------------


<!--
function animationdiv(id){
document.getElementById(id).style.visibility="visible"
}
function toggle_visibility(id) {
var e = document.getElementById(id);
if(e.style.display == 'none')
e.style.display = 'block';
else
e.style.display = 'none';
}
//-->

//------------------------------------------------
//IMAGE SWAPING SCRIPT STARTS


<!--
function FP_swapImgRestore() {//v1.0
 var doc=document,i; if(doc.$imgSwaps) { for(i=0;i<doc.$imgSwaps.length;i++) {
  var elm=doc.$imgSwaps[i]; if(elm) { elm.src=elm.$src; elm.$src=null; } } 
  doc.$imgSwaps=null; }
}

function FP_swapImg() {//v1.0
 var doc=document,args=arguments,elm,n; doc.$imgSwaps=new Array(); for(n=2; n<args.length;
 n+=2) { elm=FP_getObjectByID(args[n]); if(elm) { doc.$imgSwaps[doc.$imgSwaps.length]=elm;
 elm.$src=elm.src; elm.src=args[n+1]; } }
}

function FP_preloadImgs() {//v1.0
 var d=document,a=arguments; if(!d.FP_imgs) d.FP_imgs=new Array();
 for(var i=0; i<a.length; i++) { d.FP_imgs[i]=new Image; d.FP_imgs[i].src=a[i]; }
}

function FP_getObjectByID(id,o) {//v1.0
 var c,el,els,f,m,n; if(!o)o=document; if(o.getElementById) el=o.getElementById(id);
 else if(o.layers) c=o.layers; else if(o.all) el=o.all[id]; if(el) return el;
 if(o.id==id || o.name==id) return o; if(o.childNodes) c=o.childNodes; if(c)
 for(n=0; n<c.length; n++) { el=FP_getObjectByID(id,c[n]); if(el) return el; }
 f=o.forms; if(f) for(n=0; n<f.length; n++) { els=f[n].elements;
 for(m=0; m<els.length; m++){ el=FP_getObjectByID(id,els[n]); if(el) return el; } }
 return null;
}
// -->



//IMAGE SWAPING SCRIPT ENDS
//-------------------------------------------------------



//SEARCH DIV OVERLAY SHOW/HIDE SCRIPT START FROM HERE
//-------------------------------------------------------


//Start Overlay Script



function getposOffset(overlay, offsettype){
var totaloffset=(offsettype=="left")? overlay.offsetLeft : overlay.offsetTop;
var parentEl=overlay.offsetParent;
while (parentEl!=null){
totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
parentEl=parentEl.offsetParent;
}
return totaloffset;
}

function overlay(curobj, subobjstr, opt_position){
if (document.getElementById){
var subobj=document.getElementById(subobjstr)
subobj.style.display=(subobj.style.display!="block")? "block" : "none"
var xpos=getposOffset(curobj, "left")+((typeof opt_position!="undefined" && opt_position.indexOf("right")!=-1)? -(subobj.offsetWidth-curobj.offsetWidth) : 0) 
var ypos=getposOffset(curobj, "top")+((typeof opt_position!="undefined" && opt_position.indexOf("bottom")!=-1)? curobj.offsetHeight : 0)
subobj.style.left=xpos+"px"
subobj.style.top=ypos+"px"
return false
}
else
return true
}


function overlay1(curobj, subobjstr, opt_position){
if (document.getElementById){
var subobj=document.getElementById(subobjstr)
subobj.style.display=(subobj.style.display!="block")? "block" : "none"
//var xpos=getposOffset(curobj, "right")+((typeof opt_position!="undefined" && opt_position.indexOf("left")!=-1)? -(subobj.offsetWidth-curobj.offsetWidth) : 0) 
//var ypos=getposOffset(curobj, "bottom")+((typeof opt_position!="undefined" && opt_position.indexOf("top")!=-1)? curobj.offsetHeight : 0)
//subobj.style.left=xpos+"px"
//subobj.style.top=ypos+"px"
subobj.style.left=630+"px"
subobj.style.top=210+"px"
return false
}
else
return true
}

function overlayclose(subobj){
document.getElementById(subobj).style.display="none"
}

//end overly script


function confirmlink(msg,links) {

var checkin = confirm(msg);
if(checkin) {
window.location = links;
}else {
return false;
}

}


//SEARCH DIV OVERLY SHOW/HIDE SCRIPT ENDS HERE
//------------------------------------------------------


//-----------------------------------------------------------
//DROP IN  OUT BOX SCRIPT
//-----------------------------------------------------------

var ie=document.all
var dom=document.getElementById
var ns4=document.layers
var calunits=document.layers? "" : "px"

var bouncelimit=32 //(must be divisible by 8)
var direction="up"

function initbox(targetbox){
if (!dom&&!ie&&!ns4)
return
//crossobj=(dom)?document.getElementById("dropin").style : ie? document.all.dropin : document.dropin
crossobj=(dom)?document.getElementById(targetbox).style : ie? document.all.dropin : document.dropin
scroll_top=(ie)? truebody().scrollTop : window.pageYOffset
crossobj.top=scroll_top-250+calunits
crossobj.visibility=(dom||ie)? "visible" : "show"
dropstart=setInterval("dropin()",50)
}

function dropin(){
scroll_top=(ie)? truebody().scrollTop : window.pageYOffset
if (parseInt(crossobj.top)<0+scroll_top)
crossobj.top=parseInt(crossobj.top)+10+calunits
else{
clearInterval(dropstart)
bouncestart=setInterval("bouncein()",50)
}
}

function bouncein(){
crossobj.top=parseInt(crossobj.top)-bouncelimit+calunits
if (bouncelimit<0)
bouncelimit+=8
bouncelimit=bouncelimit*-1
if (bouncelimit==0){
clearInterval(bouncestart)
}
}

function dismissbox(){
if (window.bouncestart) clearInterval(bouncestart)
crossobj.visibility="hidden"
}

function truebody(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}


//window.onload=initbox


//-----------------------------------------------------------
//END OF DROP IN  OUT BOX SCRIPT
//-----------------------------------------------------------