function logout() {
if (confirm("Are you sure you'd like to logout?")) {
location.href = "/logout.php";
}
}

function toolbarlogout() {
if (confirm("Are you sure you'd like to logout?")) {
location.href = "/toolbarlogout.php";
}
}

function logout2() {
if (confirm("Are you sure you'd like to logout?")) {
location.href = "/logout.php";
}
}

function del(loc) {
var x = confirm("Are you sure?");
if (x == true) {
window.location = loc;
}
}

  function unban_confirm(item,label)
  {
  var name=confirm("Really unban " + label + " (" + item + ") ?")
  if (name==true)
  {
  window.location="forum.php?step=unban&id=" + item + "";
  }
  }

  function ipunban_confirm(item)
  {
  var name=confirm("Really delete ban #"  + item + " ?")
  if (name==true)
  {
  window.location="?ipban&unban=" + item + "";
  }
  }

function post() {
	document.bulletin.action = "?post2";
	document.bulletin.submit();
	return true;
}

function preview() { 
	document.bulletin.action = "?post";
	document.bulletin.submit();
	return true;
}

function preview(yesOr) {
  var name=confirm("Have you read the bulletin rules?")
  if(name) {
    if (yesOr == 1) { document.bulletin.action = "?preview"; document.bulletin.submit(); return true; }else{
      document.bulletin.action = "?post2"; document.bulletin.submit(); return true;
    }
  }else{ return false; }
}

function doclear() {
document.post.msg.value = "";
}

function clearmsg() {
window.setTimeout("doclear()",250);
return 1;
}