Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

duplicate row for editing

 
deepa karra
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am retreving a row from a table using struts and hibernate and displaying it on a jsp page. How can I create a duplicate row of the displayed record on a button click for editing in the same jsp page?
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64985
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Reacting to a button click to do anything other than submit a form requires JavaScript. Perhaps you can supply a more detailed description of what you are trying to accomplish.
 
Nilesh Miskin
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As Bear rightly said, you need JavaScript to get your job done. When you click the button, javascript can be used to populate the values in proper html elements (e.g. a text input). Here you can modify the record & submit the form to update the table in your database as per the business logic.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic