我想在下面填写此表格
<form enctype="application/x-www-form-urlencoded" action="http://cpanel.gateway245.com/auth" method="post">
<p class="element">
<label for="email">Email address</label>
<br/>
<input type="text" name="email" id="email" value="" placeholder="E-mail">
</p>
<p class="element">
<label for="password">Password</label>
<br/>
<input type="password" name="password" id="password" value="" placeholder="Password">
</p>
<input type="submit" name="submit" id="submit" value="Login">
</form>
因此,当点击一个链接时,表单显示我看到一些带有登录表单的网站,这样可以在div菜单ui下用html完成吗?
答案 0 :(得分:0)
显示/隐藏内容无法仅在HTML中完成 - 您需要使用JavaScript来处理点击事件。
这是一个让您走上正轨的基本示例。已有很多很多很多例子。
CSS
#ttt { display: none; }
HTML
<a href="#" onclick="show('ttt')">Click to show form</a>
<form id="ttt"> ... </form>
JavaScript
function show(target){
document.getElementById(target).style.display = 'block';
}