function popUp(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=400,height=400,left = 810,top = 400');");
}
function updatecolor(){
	
	var col='#'+document.getElementById("bcolor").value;
	document.getElementById("color").style.backgroundColor=col;
}
function Showbordercolor(color){
	
        if(color=='1')
	 {
	 document.getElementById("bcolor").style.backgroundColor='#ffffff';
          document.getElementById("bcolor").style.color='#000000';
	 document.simplecanvas.bcolor.value='FFFFFF';
         document.simplecanvas.bcolor.disabled=true;
	 }
	 else if(color=='0')
	 {
	 document.getElementById("bcolor").style.backgroundColor='#000000';
         document.getElementById("bcolor").style.color='#ffffff';
	 document.simplecanvas.bcolor.value='000000';
         document.simplecanvas.bcolor.disabled=true;
	 }
         else if(color=='2')
         {
         document.getElementById("bcolor").style.backgroundColor='#c0dffd';
         document.getElementById("bcolor").style.color='#000000';
	 document.simplecanvas.bcolor.value='C0DFFD';
         document.simplecanvas.bcolor.disabled=false;

         }
	
}
function Showborder(divId){
	
	 
	 document.getElementById("img").style.backgroundColor='#ffffff';
	 document.getElementById("mirror").style.backgroundColor='#ffffff';
	 document.getElementById(divId).style.backgroundColor='#ABE6A8';

}
function Show(divId,id){
		 
    
	
	 if(id=='two')
	 {
	// document.getElementById("one").style.backgroundColor='#ffffff';
	 document.getElementById("two").style.backgroundColor='#ABE6A8';
	 document.getElementById("three").style.backgroundColor='#ffffff';
	 document.getElementById("four").style.backgroundColor='#ffffff';
	
	
	 
	  
	 }
	 else if(id=='three')
	 {
	// document.getElementById("one").style.backgroundColor='#ffffff';
	 document.getElementById("two").style.backgroundColor='#ffffff';
	 document.getElementById("three").style.backgroundColor='#ABE6A8';
	 document.getElementById("four").style.backgroundColor='#ffffff';
	     
	 
	  }
        else if(id=='four')
	 {
	// document.getElementById("one").style.backgroundColor='#ffffff';
	 document.getElementById("two").style.backgroundColor='#ffffff';
	 document.getElementById("three").style.backgroundColor='#ffffff';
	 document.getElementById("four").style.backgroundColor='#ABE6A8';
	     
	 
	  }
	 
	 updatePrice();
}
function addOption(selectbox,text,value )
{
var optn = document.createElement("OPTION");
optn.text = text;
optn.value = value;
selectbox.options.add(optn);
}
function ShowHide(divId){
	
	if(divId=='custom')
	  {
		document.simplecanvas.canvas_h.disabled=false;
		document.simplecanvas.canvas_w.disabled=false;
		for (i=0; i<document.simplecanvas.CanSize.length; i++) 
		{
		 document.simplecanvas.CanSize[i].disabled=true;
         if (document.simplecanvas.CanSize[i].checked==true)
         {
		  //document.simplecanvas.CanSize[i].checked=false;
         }
        }  
		
	  }
	else if(divId=='standard'){
		 document.simplecanvas.canvas_h.disabled=true;
		 document.simplecanvas.canvas_w.disabled=true;
		 for (i=0; i<document.simplecanvas.CanSize.length; i++) 
		 {
		 document.simplecanvas.CanSize[i].disabled=false;
         }  
		 
		}
	updatePrice();
 }

