// JavaScript Document

function showLoad () {
	$('load').style.display = 'load';
}

function showResponse (originalRequest) {
	var newData = originalRequest.responseText;
	$('load').style.display = 'none';
	$('tabbed-content').innerHTML = newData;
	//$('content').src = 192.168.1.25:8800/materials.html?id=lha;
}

function colorBorder(img){
	img.style.border = '2px solid #98b3fd';
}

function defaultBorder(img){
	img.style.border = '2px solid #FFF';
}

function openWindow(url, name){
	var	mywindow =	window.open(url,name,'toolbar=no,location=middle,width=640,height=480,directories=no,status=no,menubar=no,resizable=yes,copyhistory=no,scrollbars=yes');
}

function loadAjax(divID, desturl, startIndex, action){

//	$("#" + divID).load(desturl);

	$.ajax({
		type: "POST",
		url: desturl,
		data: "startIndex=" + startIndex + "&action=" + action,
		success: function(msg){
			//alert('divId text : ' + msg );
			document.getElementById(divID).innerHTML = msg;
			return;
        },
		error: function(msg){
			alert( "error occured: " + msg.responseText );
		}
 });
}
