Sheet Pangasa wrote:I want to read these in my JSP page using loop but i am unable to do so.
Bear Bibeault wrote:And why are you using JavaScript to create the options rather than just constructing straight-forward HTML? You're making things much more complicated than they need to be.
Bear Bibeault wrote:You would use Ajax for that.
Sheet Pangasa wrote:
Bear Bibeault wrote:You would use Ajax for that.
Would have already used that if I had knowledge in this field. Probably would not have come here to ask such silly questions :)
Btw, i have resolved it by using the below code in servlet itself (dont care much if it is right approach or not but it is working for me):
Thanks for your time.
Albareto McKenzie wrote:
That's the problem, that you don't care, but being honest that code sucks, you should not put 20 attributes in the request(*), specially not 20 variables that come from a List!! So you iterate the List in your Servlet to set the request attributes and then you iterate it in the JSP to put them in the option list... looks overkilling to me, why don't you just say in the Servlet:
Don't get me started about those stupid light bulbs. |