87,910
社区成员
发帖
与我相关
我的任务
分享
<html>
<head>
<title>创建Cookie演示</title>
<script language=“JavaScript">
<!--
function makeCookie(){
alert ("点击了按钮创建!");
}
function welcome(){
alert("嘿嘿,还没有Cookie");
}
-->
</script>
</head>
<body bgcoloR="lightgrey" onLoad="document.form1.reset()" >
<center>
<h2>用户登录</h2>
<form name="form1">
用户名:
<input type="text" name="yourname">
<p>
密码:
<input type="text" name="passwd">
<p>
<input type="button" value="创建Cookie" onClick="makeCookie();">
<p>
<input type="button" value="查看Cookie" onClick="welcome();">
<p>
</form>
</body>
</html>
<html>
<head>
<title>创建Cookie演示</title>
<script language="JavaScript">
<!--
function makeCookie(){
alert ("点击了按钮创建!");
}
function welcome(){
alert("嘿嘿,还没有Cookie");
}
-->
</script>
</head>
<body bgcoloR="lightgrey" onLoad="document.form1.reset()" >
<center>
<h2>用户登录</h2>
<form name="form1">
用户名:
<input type="text" name="yourname">
<p>
密码:
<input type="text" name="passwd">
<p>
<input type="button" value="创建Cookie" onClick="makeCookie();">
<p>
<input type="button" value="查看Cookie" onClick="welcome();">
<p>
</form>
</body>
</html>
<script type="text/javascript">
function makeCookie(){
alert ("点击了按钮创建!");
}
function welcome(){
alert("嘿嘿,还没有Cookie");
}
</script>
<html>
<head>
<title>创建Cookie演示</title>
</head>
<body bgcoloR="lightgrey" onLoad="document.form1.reset()" >
<center>
<h2>用户登录</h2>
<form name="form1">
用户名:
<input type="text" name="yourname">
<p>
密码:
<input type="text" name="passwd">
<p>
<input type="button" value="创建Cookie" onClick= alert("点击了按钮");>
<p>
<input type="button" value="查看Cookie" onClick= alert("嘿嘿,还没有Cookie");>
<p>
</form>
</body>
</html>