//=======================================================
//ポップアップ
//=======================================================

function OpenWin(path, win_name, win_size){
    win=window.open(path,win_name,win_size+",toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,favorites=no,resizable=no");
}

//=======================================================
//お気に入りに追加
//=======================================================

function addBookmark(title,url)
{
	if (window.sidebar)
	{
		window.sidebar.addPanel(title, url, "");
	}
	else if( document.all )
	{
		window.external.AddFavorite( url, title);
	}
	else if( window.opera && window.print )
	{
		return true;
	}
}

//=======================================================
//画像のチェンジ
//=======================================================

function changeImages(imagename,imagefile) {
if (document.layers) {
	document.images[imagename].src = imagefile; 		// for N4
	}
else if (document.getElementById) {
	document.getElementById(imagename).src = imagefile; 	// for IE5, N6
	document.getElementById(imagename).style.border=0;
	}
else	{
	document.all(imagename).src = imagefile; 			// for IE4
	}
}


function showhide(id){
  if(document.getElementById){
    if(document.getElementById(id).style.display == "none")
      document.getElementById(id).style.display = "block";
    else
      document.getElementById(id).style.display = "none";
  }
}


//=======================================================
//携帯電話にメールを送る
//=======================================================

function mailTo(){
	_mailadr = document.getElementById('mailaddress').value;

	// アドレス文法チェック
	if(!_mailadr.match(/^\S+@\S+$/)){
		alert("メールアドレスを入力してください");
		return 0;
	}else{
		// メールアドレスが正しかったら
		_subject = "xxxxxx MOBILE";
		_body    = "Fiore url   http://www.xxxxxxxxxxxx.com/m/";
		location.href="mailto:" + _mailadr + "?subject=" + _subject + "&body=" + _body;
	}
}

//=======================================================
//右クリックメニューを出さない
//=======================================================

//document.oncontextmenu = function() { return false }; 

