function checkvalue(f){

	if(f.account.value==""){

		alert("You are not login, login first, please!");

		return false;

	}

	
    if(f.op.value=="reply" && f.orderid.value==""){

		alert("please select a message!");

		//f.orderid.focus();

		return false;

	}

	if(f.op.value!="del" && f.content.value==""){

		alert("please input some words of content!");

		f.content.focus();

		return false;

	}

	return true;

}

function onDropClick(f,id,showid){

	if(!confirm("already to delete this entry ("+showid+")?"))

		return false;

	else{

		f.memoid.value=id;

		f.op.value="del";

		f.submit();

	}

}

function onReplyClick(f,id,showid,md5id){

	var obj=document.getElementById('optitle');

	if(obj)

		obj.innerHTML="Reply the entry of "+showid;

	f.memoid.value=id;

    f.orderid.value=id;

    f.orderid.readOnly=true;

	f.content.value="";

	f.op.value="reply";

	f.content.focus();

}

function onPostClick(f,id){

	var obj=document.getElementById('optitle');

	if(obj)

		obj.innerHTML="Post new entry";

	f.memoid.value=id;

	f.content.value="";

	f.op.value="post";

	f.content.focus();

}

function onEditClick(f,id,showid,md5id){

	var obj=document.getElementById('optitle');

	if(obj)

		obj.innerHTML="Edit the entry of "+showid

	obj=document.getElementById('memocontent'+id);

	if(obj){

		con=obj.innerHTML;


		f.content.value=con;

	}	

	f.memoid.value=id;

    f.orderid.value=id;

    f.op.value="edit";

	f.content.focus();

}

