function preventSubmitTwice(button)
{

// 関数を書き換える
  preventSubmitTwice = function()
  {
    alert("ただいま処理中です。しばらくお待ち下さい。");
    return false;
  }

  // ボタンの無効化
  button.disabled = true;
  return true;
}

function preventSubmitTwice2Button(button1, button2)
{

 // 関数を書き換える
  preventSubmitTwice2Button = function()
  {
    alert("ただいま処理中です。しばらくお待ち下さい。");
    return false;
  }

  // ボタンの無効化
  button1.disabled = true;
  button2.disabled = true;
  return true;
}
