<script>
function operate()
{
document.getElementById('div_test').style.display="";
setTimeout("disappeare()",2000);
}
function disappeare(){
document.getElementById('div_test').style.display="none";
}
</script>
</head>
<body>
<input type="button" onclick="javascript:operate()" value="操作"/>
<div id="div_test" style="display:none;color:white;line-height:25px;position:absolute;z-index:100;left:50%;top:2%;margin-left:-75px;text-align:center;width:150px;height:25px;font-size:12px;">
恭喜你,操作成功!
</div>