<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
</head>
<body onLoad="time()">
<script>
function time()
{
var time = new Date();
var hour = time.getHours();
var minute = time.getMinutes();
var second = time.getSeconds();
var show = ((hour>=12)?" 下午 ":" 上午 ");
show = show+((hour>=12)?hour-12:hour);
show = show+((minute<10)?":0":":")+minute;
show = show+((second<10)?":0":":")+second;
setTimeout("time()",1000);
document.f1.t1.value=show;
}
function document.onmousedown(){
var flag = confirm("你再点一下试试");
if(flag){
alert("点击确定进入");
}else{
alert("点击取消进入");
}
}
</script>
<form name=f1>
<input type="text" name=t1 readonly onClick="javascript:if(confirm('确定'))alert('好的');">
</form>
</body>
</html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
</head>
<body onLoad="time()">
<script>
function time()
{
var time = new Date();
var hour = time.getHours();
var minute = time.getMinutes();
var second = time.getSeconds();
var show = ((hour>=12)?" 下午 ":" 上午 ");
show = show+((hour>=12)?hour-12:hour);
show = show+((minute<10)?":0":":")+minute;
show = show+((second<10)?":0":":")+second;
setTimeout("time()",1000);
document.f1.t1.value=show;
}
function document.onmousedown(){
var flag = confirm("你再点一下试试");
if(flag){
alert("点击确定进入");
}else{
alert("点击取消进入");
}
}
</script>
<form name=f1>
<input type="text" name=t1 readonly onClick="javascript:if(confirm('确定'))alert('好的');">
</form>
</body>
</html>