(This is for a Cattle Drive assignment, so technically you're not helping me with homework!)
I am coding a
servlet class that gets input from a form, creates an object using that input ( there are 6 parameters needed to create the object ) and puts it into an ArrayList. This servlet class also needs to provide a way to access the objects in the ArrayList and send the values stored for each of the six attributes to a
jsp where they will be displayed in a table.
I've got everything working <b>except</b> only the last object in the ArrayList is being displayed in the table.
I've been going around in circles until I'm dizzy trying to figure out how the attributes in the request object are sent from the servlet class to the jsp, and exactly what is in that response.
I can't figure out if the problem is in my servlet class, where the code for setting the attributes for the request object is part of a for block that iterates through my ArrayList, getting each object and setting the 6 attributes for each, and when the block completes, forwards the whole thing to the jsp, where only the last object is being printed in the table; <b>or</b> in the jsp itself, where the code for printing out the table data might be faulty (i.e. it only prints one row of the table, rather than iterating through the who;e list list).
How can I check to see what is being forwarded with the response from the servlet to the jsp?
[ May 01, 2006: Message edited by: Bear Bibeault ]