gpt4 book ai didi

php - 如何将操作固定到按钮

转载 作者:行者123 更新时间:2023-11-28 11:16:32 24 4
gpt4 key购买 nike

这是我的 index.html。我想在单击按钮时采取行动 checklogin.php。这就是我所做的,但它在按钮上显示文本。我应该在哪里粘贴我的操作?谁能给我一个建议?

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link rel="stylesheet" type="text/css" href="logs.css" />
</head>

<body>
<div class="container">
<form id="signup">
<div class="header">
<h3>Logowanie</h3>

</div>
<div class="sep"></div>
<div class="inputs">
<input type="myusername" placeholder="Login" autofocus />
<input type="mypassword" placeholder="Hasło" /> <a id="submit">
<form name="form1" method="post" action="check.php">
<input type="submit" name="Submit" value="OK"> </form> Zaloguj </a>

</div>
</form>
</div>
</body>
</html>

这是我的 CSS:

#signup .inputs #submit {
width: 100%;
margin-top: 20px;
padding: 15px 0;
color: #fff;
font-size: 14px;
font-weight: 500;
letter-spacing: 1px;
text-align: center;
text-decoration: none;
background: -moz-linear-gradient(top, #b9c5dd 0%, #a4b0cb);
background: -webkit-gradient(linear, left top, left bottom, from(#b9c5dd), to(#a4b0cb));
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
border-radius: 5px;
border: 1px solid #737b8d;
-moz-box-shadow: 0px 5px 5px rgba(000, 000, 000, 0.1), inset 0px 1px 0px rgba(255, 255, 255, 0.5);
-webkit-box-shadow: 0px 5px 5px rgba(000, 000, 000, 0.1), inset 0px 1px 0px rgba(255, 255, 255, 0.5);
box-shadow: 0px 5px 5px rgba(000, 000, 000, 0.1), inset 0px 1px 0px rgba(255, 255, 255, 0.5);
text-shadow: 0px 1px 3px rgba(000, 000, 000, 0.3), 0px 0px 0px rgba(255, 255, 255, 0);
display: table;
position: static;
clear: both;
}

最佳答案

Live Demo

首先这里是有效的HTML

<div class="container">
<form name="form1" method="post" action="check.php">
<div class="header">
<h3>Logowanie</h3>
</div>
<div class="sep"></div>
<div class="inputs">
<input type="myusername" placeholder="Login" autofocus />
<input type="mypassword" placeholder="Hasło" />
<a id="submit" href="#">Zaloguj </a>
</div>
</form>
</div>

其次,如果您需要连接链接,请执行此操作

window.onload=function() {
document.getElementById("submit").onclick=function() {
document.form1.submit();
return false;
}
}

第三,你只需要在 CSS 上使用它

#submit {

关于php - 如何将操作固定到按钮,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21735962/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com