<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>登录</title>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs
/jquery/1.4.2/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function (){
$("#un").click(function (){
$("form").submit();
});
});
</script></head>
<body>
<form action="index.php" method="post">
<input id="un" readonly="readonly" type="text" name="code" value="username" />
<input type="text" readonly="readonly" name="password" value="password" />
<input type="hidden" name="type_val" value="1" />
<input type="hidden" name="keeplive" value="1" />
<input type="hidden" name="submit" value="立即登录" />
</form>
</body>
</html>
我想post一个key是submit,value等于"立即登录"的键值对,应该怎么办呢?等同于下面点击立即登录的效果<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>登录</title></head>
<body>
<form action="index.php" method="post">
<input id="un" readonly="readonly" type="text" name="code" value="username" />
<input type="text" readonly="readonly" name="password" value="password" />
<input type="hidden" name="type_val" value="1" />
<input type="hidden" name="keeplive" value="1" />
<input type="submit" name="submit" value="立即登录" />
</form>
</body>
</html>
解决方案 »
- jquery easyui combotree 的onSelect事件
- 哪位高人给我解释一下这句话什么意思 ,出自哪里?
- JQUERY怎么得到 CLASS
- 无函数名的函数
- 如何实现javascript实现树形菜单,急!在线等。
- 问一段javascript代码的意思
- 分析:.html文件在托盘里直接打开就没有问题,但是用ie打开却不能把数据库里的数据读出来?我的web server是tomcat!
- js中这段话是什么意思呢!一定给分!
- 请问各位大侠,/[^\x00-\xff]/g, 这样表达的意思是什么呢??有什么作用呢?
- JQUERT如何设置A标记灰掉
- 如何用jquery判断浏览器类型?
- 如何控制一个浮动层在某一个标签的下方
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>登录</title></head>
<body>
<form action="index.php" method="post">
<input id="un" readonly="readonly" type="text" name="code" value="username" />
<input type="text" readonly="readonly" name="password" value="password" />
<input type="hidden" name="type_val" value="1" />
<input type="hidden" name="keeplive" value="1" />
<input type="hidden" name="submit" value="立即登录" />
<input type="submit" value="立即登录" />
</form>
</body>
</html>
我想用第一种方法实现(也就是用javascript实现)。