jsp两个按钮跳转传值

2025-05-14 04:09:14
推荐回答(6个)
回答1:










在f1(),f2()中设定提交的页面

回答2:

那你可以获取到按钮的值,
根据按钮值的不同去判断他的值不同,
跳到不同的页面···

要是不行你把你的代码粘贴出来 看看

回答3:

给个简单例子

回答4:

reader.jsp关键代码:

回答5:

给个简单例子
type="button"
onclick="window.location.href='anotherjsp.jsp?key=value'">

回答6:



language="javascript">
function
f1()
{
document.frm1.action="1.jsp"
document.frm1.submit()
}
function
f2()
{
document.frm1.action="2.jsp"
document.frm1.submit()
}

name="frm1"
method="post">
type="button"
onclick="f1()"
value="b1">
type="button"
onclick="f2()"
value="b2">



在f1(),f2()中设定提交的页面