现在我们需要一个简单的帐号和密码来控制我们的web入口地址,我们的开发环境是javascript下面是我们的代码

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
<script language="JavaScript" type="text/javascript">
function sc()
{
    alert("xmphoenix!");
}

function check()
{
    var name=document.getElementById("user").value;
    var Passwd=document.getElementById("passwd").value;
    if(name=="xmphoenix"&&Passwd=="xmphoenix")
    {
        alert("登录成功!");
        window.location.href="index.html"
    }
    else
    {
        alert("没有此帐号!或者密码错误!");
    }
}

</script>
<style type="text/css">
<!--
#Layer1 {
    position:absolute;
    width:378px;
    height:184px;
    z-index:1;
    left: 282px;
    top: 57px;
}
-->
</style>
</head>

<body>
<div >

相关文章:

  • 2021-11-23
  • 2022-12-23
  • 2022-02-23
  • 2021-07-09
  • 2021-10-29
  • 2021-08-17
猜你喜欢
  • 2021-11-23
  • 2021-11-23
  • 2021-04-08
  • 2022-12-23
  • 2021-11-23
  • 2022-12-23
  • 2021-11-23
相关资源
相似解决方案