jsp 页面之间的传参方法

来源:百度知道 编辑:UC知道 时间:2024/06/28 06:03:32
我在第一个页面中查出数据库中的值,在第二个页面中我想用这些值,用什么方法可以实现变量值的传递呢?

在form表单中做提交
<form name="myform" action="checklogon.jsp" method="post">
<input type="text" name="name"/>
</form>
或者使用a标记挂“?”;来传参。
<a href="showforother.jsp?currentNumber=<%=currentNumber %>"><img src="<%=basePath %>images/show.jpg" border="0" /></a>
都是用request.getParameter("参数名")来接参。