3
這是一個非常簡單的問題,但我是一個新手...連接一個JSP頁面到另一個jsp頁面
我有兩個文件:login.jsp的和report.jsp 它們都在同一個WebContent文件夾。
我想在report.jsp該按鈕時,會帶我去的login.jsp
頁面的JSP部分看起來像一個鏈接:
Connection conn = (Connection)session.getAttribute("conn"); //retrieves the connection from the session
String lot_id = request.getParameter("lotnum");
session.setAttribute("lot_id",lot_id);
out.print("Report on Lot Number: ");
out.print(request.getParameter("lotnum")+"<br>");
//<a href="login.jsp">Click here to go to login page</a>
// this is supposed to be an anchor tag linking this page to login.jsp, and where I am getting my error...
Statement sql = conn.createStatement(); //create statement using the connection
//... ... code for the rest of the page goes here...
謝謝你,
非常感謝
我有多傻。當然... out.print可以發送html代碼...謝謝! – user3044023