function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}



function showNavi(pageNo, totalCount, listSize, pageChangerFunctionName)
{
	if (pageChangerFunctionName == null) pageChangerFunctionName = 'changePage';
	if (listSize == null) listSize = 10;
	var totalPage = parseInt(totalCount / listSize) + 1;
	if (totalCount % listSize == 0) totalPage--;
	var viewPage = parseInt(pageNo / 10);
	if (pageNo % 10 == 0) viewPage--;
	viewPage *= 10;

	//showQuickButton("ico_first", pageNo != 1 ? 1 : null, pageChangerFunctionName);
	showQuickButton("<img src=img/btn_nav_prev.gif width=3 height=5> ÀÌÀü", totalPage > 9 ? viewPage : null, pageChangerFunctionName);

	document.write("<font color='#999999'>");
	viewPage++;
	for (var i=0; i<10; i++)
	{
		showDelimiter();
		if (pageNo == viewPage) {
			document.write("<span class='bbs' style='color: #999999'>" + viewPage + "</span>");
		} else {
			document.write("<a style='padding: 0 2; cursor:pointer; color: #231F20' onclick="+pageChangerFunctionName+"(" + viewPage + ")");
			document.write(" onmouseover=\"this.style.background='#eeeeee'\"");
			document.write(" onmouseout=\"this.style.background='#ffffff'\"");
			document.write(" class='bbs'><b>" + viewPage + "</b></a>");
		}
		if (++viewPage > totalPage) break;
	}
	showDelimiter();
	document.write("</font>");

	showQuickButton("´ÙÀ½ <img src=img/btn_nav_next.gif width=3 height=5>", viewPage <= totalPage ? viewPage : null, pageChangerFunctionName);
	//showQuickButton("ico_end", pageNo != totalPage ? totalPage : null, pageChangerFunctionName);

//	function showDelimiter() { document.write("</b><span style='font-size: 9pt; color: #CDCDD1'>|</span><b>");	}
	function showDelimiter() { document.write(" | ");	}
	function showQuickButton(imgName, pageNo, pageChangerFunctionName) {
		var style = "align=absmiddle border=0 hspace=3";
		if (pageNo == null || pageNo == 0) document.write(imgName);
		else document.write("<a href=# onclick="+pageChangerFunctionName+"(" + pageNo + ") style=cursor:pointer " + style + ">"+imgName+"</a>");
	}
}
