| Author |
how to find which data the user clicked
|
Prasanna RamKumar
Ranch Hand
Joined: Nov 30, 2005
Posts: 31
|
|
iam creating a table in jsp page so that all data inside the table will link to a common servlet is there any way to find which data the user clicked please help me prasanna
|
 |
Cm Ananth
Ranch Hand
Joined: Oct 20, 2005
Posts: 44
|
|
While creating the table, you need to put an identifier to differentiate rows. and that identifier needs to be passed to the common servlet to idntify which row of the table is selected.. take for example, while construting the URL itself, you can append an identifier at the end, in that way you can reuse that in the common servlet. let me know if you need any sample code for that.
|
By Ananth, Bangalore
|
 |
Prasanna RamKumar
Ranch Hand
Joined: Nov 30, 2005
Posts: 31
|
|
|
please send me the sample code
|
 |
Prasanna RamKumar
Ranch Hand
Joined: Nov 30, 2005
Posts: 31
|
|
this is my jsp page <html> <head><title>JSP Page</title></head> <body> <table border="1"> <tr> <th> index </th> </tr> <tr> <td><a href ="hello" >one</a></td> </tr> <tr> <td><a href ="hello ">two</a></td> </tr> <tr> <td><a href ="hello ">three</a></td> </tr> </table> </body> </html> hello is the servelt name when the user clicks on hyperlinks i want to know which one he clicks
|
 |
Ben Souther
Sheriff
Joined: Dec 11, 2004
Posts: 13410
|
|
|
|
Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
|
 |
 |
|
|
subject: how to find which data the user clicked
|
|
|