// JavaScript Document
function display(id)
{



if(id=='business')
{
	document.getElementById("map_content").innerHTML='<h2>Business Architecture</h2><div>When you are ready to move past the rhetoric and take a close look at the implication of Cloud computing in you Enterprise, our Business Architecture Prototype can help you realize that goal. Our experts will work collaboratively with your leadership team to define the goals, analyze the current state and strategize on the potential implications of adopting Cloud Computing. We achieve this by detailed analysis of your business goals and by developing quick prototypes that depict the end state capabilities.</div>';
}

else if(id=='roadmap')
{
	document.getElementById("map_content").innerHTML='<h2>Roadmap Planning</h2><div>Paradigms as radical as Cloud Computing need an ambitious yet phased approach to its adoption. Using our unique "Cloud Maturity" model, Cumulux will help define a phased roadmap that reduces risk, maximizes impact, and leverage a hybrid approach. We are strong proponents of a model that blends On-Premise and Cloud Computing to ensure a fundamentally sound roadmap to Cloud adoption. </div>';
}

else if(id=='enterprise')
{
	document.getElementById("map_content").innerHTML='<h2>Enterprise Architecture</h2><div>Understanding and adopting a disruptive phenomenon like Cloud Computing is a complex undertaking for the CIO. Our experts come with decades of industry experience from Microsoft, Oracle, and PeopleSoft and can be the trusted advisors to the CIO\'s office for vendor agnostic evaluation of the various platforms and to craft a detailed strategy for Cloud Computing adoption. We look at the four pillars of Enterprise Architecture - Business, Process, Information and Technology Architecture -- to give you a comprehensive read into its potential impact and will help define a strategy to implement.</div>';
}

else if(id=='portfolio')
{
	document.getElementById("map_content").innerHTML='<h2>Portfolio Analysis</h2><div>Enterprise Applications are complex compositions of business capabilities that are critical to its operational and strategic objectives. Not all applications are naturally suited to be moved to the Cloud immediately. Cumulux utilizes its home-grown 5-Dimensional model to analyze the potential fit of these applications to the Cloud Computing environment based on their maturity, TCO, exposure, operational complexity and computational needs. This enables the Enterprise to clearly identify the applications that are prime candidates for the Cloud Computing model.</div>';
}

else if(id=='economic')
{
	document.getElementById("map_content").innerHTML='<h2>Economic Impact Analysis</h2><div>Before embarking on the road to Cloud Computing adoption, Enterprises need to understand the potential economic impact of this strategy. By using industry standard "Total Economic Impact" framework, Cumulux can analyze the Cost, Risks, Benefits, and Flexibilities associated with Cloud Computing. This enables Enterprises to clearly articulate the immediate and the future economic impact of Cloud Computing to its IT and business investments.</div>';
}

}

/* Contact us form validation */

function contact_validation()
{
	var name = document.getElementById("uname").value;
	var emailid = document.getElementById("email").value;
	reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,4})$/;
	var phone = document.getElementById("phoneno").value;
	var des = document.getElementById("descrip").value;
	
	
	if (name == "") 
	{
		hideAllErrors_contact();
        document.getElementById("unameError").style.display = "inline";
		document.getElementById("uname").select();
        document.getElementById("uname").focus();
        return false;
    }
	
    else if (emailid == "") 
	{
		hideAllErrors_contact();
    	document.getElementById("emailError").style.display = "inline";
		document.getElementById("email").select();
    	document.getElementById("email").focus();
        return false;
    }
	
	else if (reg.test(emailid) == false)
	{
		hideAllErrors_contact();
    	document.getElementById("emailvalidationError").style.display = "inline";
		document.getElementById("email").select();
    	document.getElementById("email").focus();
        return false;
	}
	
	else if (phone == "") 
	{
		hideAllErrors_contact();
    	document.getElementById("phonenoError").style.display = "inline";
		document.getElementById("phoneno").select();
    	document.getElementById("phoneno").focus();
        return false;
    }
	
	else if (isNaN(phone)) 
	{
		hideAllErrors_contact();
    	document.getElementById("phonenovalidError").style.display = "inline";
		document.getElementById("phoneno").select();
    	document.getElementById("phoneno").focus();
        return false;
    }
	
	else if (phone.length <= 7) 
	{
		hideAllErrors_contact();
    	document.getElementById("phonenolengthError").style.display = "inline";
		document.getElementById("phoneno").select();
    	document.getElementById("phoneno").focus();
        return false;
    }
	
	else if (des == "") 
	{
		hideAllErrors_contact();
    	document.getElementById("descripError").style.display = "inline";
		document.getElementById("descrip").select();
    	document.getElementById("descrip").focus();
        return false;
    }		
	return true;
		
}

function hideAllErrors_contact()
{
	document.getElementById("unameError").style.display = "none";
	document.getElementById("emailError").style.display = "none";
	document.getElementById("emailvalidationError").style.display = "none";
	document.getElementById("phonenoError").style.display = "none";
	document.getElementById("phonenovalidError").style.display = "none";
	document.getElementById("phonenolengthError").style.display = "none";
	document.getElementById("descripError").style.display = "none";
}

var c = 1;
function video1()
{
	if (c % 2) 
		msg = 'hide video';
	else 
		msg = 'show video';
	document.getElementById('video1').innerHTML = msg;
	c = c + 1;
}

function video2()
{
	if (c % 2) 
		msg = 'hide video';
	else 
		msg = 'show video';
	document.getElementById('video2').innerHTML = msg;
	c = c + 1;
}

function slide1()
{
	if (c % 2) 
		msg = 'hide slide';
	else 
		msg = 'show slide';
	document.getElementById('slide1').innerHTML = msg;
	c = c + 1;
}

function slide2()
{
	if (c % 2) 
		msg = 'hide slide';
	else 
		msg = 'show slide';
	document.getElementById('slide2').innerHTML = msg;
	c = c + 1;
}



var xmlHttp

function showUser(name,str)
{
	var reg 	 = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,4})$/;
	if(name.length==0)
	{
		alert("Enter the name");
		document.myform.name.focus();
		return false;
	} 
	else if(str.length==0)
	{
		alert("Enter the email address");
		document.myform.email.focus();
		return false;
	} 
	else if(reg.test(str) == false)
	{
		alert('Invalid email address');
		document.myform.email.value="";
		document.myform.email.focus();
		return false;
	 }
	 else
	 {
		xmlHttp=GetXmlHttpObject()
		if (xmlHttp==null)
		 {
			 alert ("Browser does not support HTTP Request")
			 return
		 }
		var url="download.php"
		url=url+"?name="+name
		url=url+"&email="+str
		url=url+"&sid="+Math.random()
		xmlHttp.onreadystatechange=stateChanged 
		xmlHttp.open("GET",url,true)
		xmlHttp.send(null);
	}
}

function stateChanged() 
{ 
if (xmlHttp.readyState==4)
 { 
	// document.getElementById("txtHint").innerHTML = xmlHttp.responseText
	window.location.href = xmlHttp.responseText;
	
 } 
}

function GetXmlHttpObject()
{
var xmlHttp=null;
try
 {
 // Firefox, Opera 8.0+, Safari
 xmlHttp=new XMLHttpRequest();
 }
catch (e)
 {
 //Internet Explorer
 try
  {
  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
  }
 catch (e)
  {
  xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
 }
return xmlHttp;
}