function doZoom(size) {
	if(size==1)
	{
		document.getElementById('contentarea').style.fontSize=parseInt(document.getElementById('contentarea').style.fontSize)+2+'px';
		document.getElementById('contentarea').style.lineHeight=parseInt(document.getElementById('contentarea').style.lineHeight)+2+'px';
	}
	if(size==2)
	{
		document.getElementById('contentarea').style.fontSize=14+'px';
		document.getElementById('contentarea').style.lineHeight=26+'px';
	}	
	if(size==3)
	{
		document.getElementById('contentarea').style.fontSize=parseInt(document.getElementById('contentarea').style.fontSize)-2+'px';
		document.getElementById('contentarea').style.lineHeight=parseInt(document.getElementById('contentarea').style.lineHeight)-2+'px';
	}
}

function doPrint() {
	if (window.print) { 
		var print_area       = document.all.liv_print_area.innerHTML;
		
		var css = '<style type="text/css">' +
				  '.content { FONT-SIZE: 14px; COLOR: #000000; LINE-HEIGHT: 120% }' +
				  '</style>' ;

		var body ='<table width="600" border="0" cellspacing="0" cellpadding="5">' +
			  	  '  <tr> ' +
			  	  '    <td  class="content" colspan="2"> ' +
			  	  print_area + 
			  	  '    </td>' +
			  	  '  </tr>' +
			  	  '</table>';

		document.body.innerHTML =  css + body  ;
		window.print();
	}
}

function play_video(weburl,contentmapid)
{
	var url = weburl + "fontfile/play_video.php?contentmapid=" + contentmapid;
	var features = "height=380,width=450,status=no,toolbar=no,resizable=no,menubar=no,location=no";
	window.open(url,'',features);
}

function showPsychologicalResult(){
	var answers = document.psy.psy_answer;
	var len = answers.length;
	var selectedAnswer = null;
	var showBox = document.getElementById("ans_div");
	var result = document.getElementById("resultTxt")
	showBox.style.display = "none";
	for(var i=0; i<len; i++){
		var isOn = answers[i].checked;
		if (isOn){
			selectedAnswer = i;
		}
	}
	if (selectedAnswer !=null ){
		var res = document.getElementById("res"+(selectedAnswer+1)).value;
		showBox.innerHTML = res;
		showBox.style.display = "block";
	}
	else{
		alert("请选择答案后再进行提交");
		showBox.style.display = "none";
	}
}
