Hi Everyone, To make the question as easy to understand as possible,I just describle my situation. In my first JSP page, I create a link to database to derive a list of book name(it is not the problem), and I would like to make each book name in the list as a hyperlink to the second JSP page which display the description of that book. But I dont know how to generate the link from 1st JSP page to 2nd JSP page to display the desription. Just make it simple, the table has 2 columns, Book name and Book Description. Thank you very much for your help. I am looking for your reply soon! Thanks again!
Before I come here, I am confused about Servlet/JSP. Ater I come here, I am more confused about it, but in systematically.
While displaying your list of books, have the primary key of your Book table as a parameter in the link. Since you have mentioned that your table has only two columns, I assume that the name field is your primary key.
Easy peasy, here's one possible solution - when creating the link the the 2nd JSP do it like this 2nd.jsp?book=Moby%20Dick, then in the 2nd JSP get that request parameter and look it up in the database
Drinking more tea is the key...
Joined: Sep 12, 2005
Very happy to see your replies, Thank you very much, Let me try your solutions now ! Thanks again !