You can get cell value with JS even when click on the cell:
I wrote the HTML table in JSP.
**Course** is is a type. For example Course cs, cs= object of type Course which had 2 attributes: id, title.
**courses** is an ArrayList of Course objects.
The HTML table displays all the courses titles in each cell. So the table has 1 column only:
This means that after user selects a table cell, for example "Course2", the title of the course- "Course2" will travel to the page where the URL is directing the user: . "Course2" will arrive in FoundS.jsp page. The identifier of "Course2" is courseId. To declare the variable courseId, in which CourseX will be kept, you put a "?" after the URL and next to it the identifier.
Please do not post JSP markup in the HTML forum. Also your example is way too broad and doesn't focus on the original question. Please limit solutions to those that target the question rather than embedding it into a larger, more complicated, example.