//Author: Kent Hsu
//Create: Feb-14-2007
//Time  : 18:00:00
//
//

function addBookMark(){
		bookmarkurl="http://www.voiis.com/"
		bookmarktitle="Voiis - Mobileaction Technology"
		if (document.all)
				window.external.AddFavorite(bookmarkurl,bookmarktitle)
}


//@para item 			the Objects for manpulate
//@para itemCount	give the total number of the lineitems.
function toggleMenu(item,itemCount) {
//alert(eval(item + "_table").id);
		if ((eval(item + "_table").style.display)=="") {
				shutOpenMenu(itemCount);
		} 
		else {
				shutOpenMenu(itemCount);
			 	eval(item + "_table").style.display="";			 	
		}				
		event.returnValue=0;
}

function shutOpenMenu(itemCount) {
		for (var i=0; i<=itemCount; i++) {
			eval("itemID" + i + "_table").style.display="none";
		}
}

function switchIFrameTagContent(iFrameID,targetTag) {
		frames[iFrameID].location = targetTag;
		event.returnValue=0;
}

function showTable(tb){
	var tbobj = document.getElementById(tb);
	var tbobj1 = document.getElementById("tb01");
	var tbobj2 = document.getElementById("tb02");
		
	tbobj1.style.display = "none";
	tbobj2.style.display = "none";
	
	tbobj.style.display = "";

}

function initable(){
	var tb = document.getElementById("table03");
	tb.style.display = "none";
}

function toogleModelTable(){
	var tb = document.getElementById("table03");
	if ( tb.style.display=="none" ){
		tb.style.display = "block";
	}else{
		tb.style.display = "none";
	}
}



function checkAgreementStatus() {
    len =  document.form1.length;
    loopValue = 0;
    acceptStatus = "NotSelected";

    while(loopValue < len) {
        
        elementType = document.form1.elements[loopValue].type;
        
        if(elementType=="radio"){
            
            tempElement =document.form1.elements[loopValue];

            if(tempElement.checked == true){
                
                    if(tempElement.value =="Yes"){
						return true;
					} 
            }
			
        }
        
        loopValue++;
    }
	alert("Sorry! In order to download this product, you must select \"Accept License Agreement\" \n on this page.");
	return false;
}

function checkAgreementStatusTW() {
    len =  document.form1.length;
    loopValue = 0;
    acceptStatus = "NotSelected";

    while(loopValue < len) {
        
        elementType = document.form1.elements[loopValue].type;
        
        if(elementType=="radio"){
            
            tempElement =document.form1.elements[loopValue];

            if(tempElement.checked == true){
                
                    if(tempElement.value =="Yes"){
						return true;
					} 
            }
			
        }
        
        loopValue++;
    }
	alert("很抱歉! 請充分了解本公司所提供的使用條款，並於點選 \"同意\" 後，方能進行下載。");
	return false;
}


