• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Junilu Lacar
  • Martin Vashko
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Knute Snortum
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Scott Selikoff
  • salvin francis
  • Piet Souris

dynamic text box value into database

 
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am using struts framework.
I have transaction table whose data i will be displaying on a JSP in tabular format based on given date.
The number of transaction records displayed may vary but i want to add a text box for each record displayed.
The user will give some price input in these text boxes and submit.

I want to insert the text boxes values into a price table.

JSP1


Please observe the id attribute of text input tag.
The values for buyer and transactionid are diplayed in the jsp1.
What should be given in text id in order to read all the text boxes values in my action class???

 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The ID isn't relevant; it's the name you need to fill in.
 
kalyen kumar
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok thanks....but then what should be name..?



What should be given in textbox name in order to read all the text boxes values in my action class???
Thanks in advance
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A name and an index, so it looks like array notation. Or it could be a map with an ID. Might also depend on which version of Struts you're using, which you don't mention.
 
No, tomorrow we rule the world! With this tiny ad:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!