<!--
var isIE  = (document.all) ? true : false;

function location_reload() {
	window.location.reload();

}

function is_hankaku_number(obj) {
	if(obj.value.match(/[^0-9.]+/)) {
		alert('半角数字で入力してください。');
		obj.focus();
		return false;
	} else return true;
}

String.prototype.trim = function() {
	return this.replace(/^\s+|\s+$/g,"");
}

function trim(st) {
	while(st){
		if (st.indexOf(" ")==0) st = st.substring(1);
		else break;
	}
	while(st){
		if (st.lastIndexOf(" ")==st.length-1) st = st.substring(0, st.length-1);
		else break;
	}
	return st;
}

function trim_all(checkform) {
	var i=0;
	while (i < checkform.length) {
		if (checkform.elements[i].type != 'file') {
			checkform.elements[i].value = checkform.elements[i].value.trim();
		}
		i++;
	}
	return true;
}

function is_null(obj, message) {
	if (obj.value.length==0) { alert(message+'\t'); obj.focus(); return true; }
	return false;
}

function layer_toggle(obj) {
	if (obj.style.display == 'none') obj.style.display = 'block';
	else if (obj.style.display == 'block') obj.style.display = 'none';
}

function swf(src,width,height){
    //if(!checkFlash()) return false;
    object = '';
    object += '<object type="application/x-shockwave-flash" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" id="param" width="'+width+'" height="'+height+'" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0">';
    object += '<param name="movie" value="'+src+'">';
     object += '<param name="quality" value="best">';
    object += '<param name="wmode" value="transparent">';
    object += '<param name="allowScriptAccess" value="always">';
     object += '<embed src="'+src+'" quality="best" wmode="transparent" bgcolor="#ffffff" menu="false" width="'+width+'" height="'+height+'" swliveconnect="true" id="param" name="param" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"><\/embed>';
    object += '<\/object>';
    document.write(object);
}
function swf_trans(src,width,height,post_no){
    //if(!checkFlash()) return false;
    object = '';
    object += '<object type="application/x-shockwave-flash" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" id="param" width="'+width+'" height="'+height+'" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0">';
    object += '<param name="movie" value="'+src+'">';
    object += '<param name="flashVars" value="'+post_no+'">';
    object += '<param name="wmode" value="transparent">';
    object += '<param name="quality" value="best">';
    object += '<param name="allowScriptAccess" value="always">';
    object += '<embed src="'+src+'" allowScriptAccess="always" quality="best" wmode="transparent" width="'+width+'" height="'+height+'" flashVars="'+post_no+'" swliveconnect="true" id="param" name="param" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"><\/embed>';
    //object += '<embed src="'+src+'" quality="best" wmode="transparent" bgcolor="#ffffff" menu="false" width="'+width+'" height="'+height+'" flashVars="post_no='+post_no+'" swliveconnect="true" id="param" name="param" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"><\/embed>';
    object += '<\/object>';
    return object;
}

function checkFlash()
{
	var hasProductInstall = DetectFlashVer(6, 0, 65);
	var hasRequestedVersion = DetectFlashVer(9, 0, 0);
	if ( hasProductInstall && !hasRequestedVersion ) {
		// MMdoctitle is the stored document.title value used by the installation process to close the window that started the process
		// This is necessary in order to close browser windows that are still utilizing the older version of the player after installation has completed
		// DO NOT MODIFY THE FOLLOWING FOUR LINES
		// Location visited after installation is complete if installation is required
		var MMPlayerType = (isIE == true) ? "ActiveX" : "PlugIn";
		var MMredirectURL = window.location;
		document.title = document.title.slice(0, 47) + " - Flash Player Installation";
		var MMdoctitle = document.title;

		AC_FL_RunContent(
			"src", "playerProductInstall",
			"FlashVars", "MMredirectURL="+MMredirectURL+'&MMplayerType='+MMPlayerType+'&MMdoctitle='+MMdoctitle+"",
			"width", "100%",
			"height", "100%",
			"align", "middle",
			"id", "name_str",
			"quality", "best",
			"bgcolor", "#869ca7",
			"name", "name_str",
			"allowScriptAccess","sameDomain",
			"type", "application/x-shockwave-flash",
			"pluginspage", "http://www.adobe.com/go/getflashplayer"
		);
	} else if (hasRequestedVersion) {
		// if we've detected an acceptable version
		// embed the Flash Content SWF when all tests are passed

	  } else {  // flash is too old or we can't detect the plugin
	    var alternateContent = 'Alternate HTML content should be placed here. '
	  	+ 'This content requires the Adobe Flash Player. '
	   	+ '<a href=http://www.adobe.com/go/getflash/>Get Flash</a>';
	    document.write(alternateContent);  // insert non-flash content
	  }

	  return hasRequestedVersion;
}

function moveIFrame(x,y,w,h) {
var pagesize = TB_getPageSize();
var PageScroll = lb_get_page_scroll_top();

var frameRef=document.getElementById("myFrame");
    frameRef.style.left=w/2-430/2;
    frameRef.style.top=((PageScroll[1])+ h/2-315/2)+ 'px'
    var iFrameRef=document.getElementById("myIFrame");
	iFrameRef.width=430;
	iFrameRef.height=315;
}

function hideIFrame(){
     document.getElementById("myFrame").style.visibility="hidden";
    document.getElementById("myFrame").style.display="none";
    document.getElementById("myFrame").width=0 +'px';
    document.getElementById("myFrame").height=0 +'px';
}

function showIFrame(){
    document.getElementById("myFrame").width=430 +'px';
    document.getElementById("myFrame").height=315 +'px';
    document.getElementById("myFrame").style.visibility="visible";
    document.getElementById("myFrame").style.display="block";

}

function url_encode(str) {
	// return str;
	return str.replace(/&/g, '%26');
	// return str.replace(/&/g, 'ccccc').replace(/\'/g, 'bbbbb').replace(/\"/g, 'aaaaa');
	// return str.replace(/&/g, '%26').replace(/\'/g, '%27');
}

function onclick_profile(slid) {
	var url = '/ajax_exe.php';
	pars = 'mode=get_profile';
	pars += '&slid='+slid;
	var myAjax = new Ajax.Request(url, { method: 'post', postBody: pars, onComplete: onclick_profile_result });
}

function onclick_profile_result(originalRequest) {
	var result = originalRequest.responseText;
	lb_window_on_profile(result);
}

function loadIFrame(url){
	document.getElementById("myFrame").innerHTML = "<iframe id='myIFrame' src='" + url + "'frameborder='0'></iframe>";
}
// param = post_no=1&lastshow=1  -- lastshow 1.show 2.hide
function openSlide(param)
{
	lb_window_on(swf_trans('http://www.modelbk.com/model/slide_gallery.swf','100%','100%',param));
}
function show_main_menu(num)
{
	document.write(swf_trans('http://img.modelbk.com/images/top/menu.swf','900','90','post_no='+num));
}

-->