Win a copy of Svelte and Sapper in Action this week in the JavaScript forum!
  • 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
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Sending data via java class

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

I have a condition where I need to sent data to a jsp from the java class.

I have 2 jsps in the same page using iframes. In the 1st jsp I am letting the user to fill a form. The details filled by the user is inserted into the DB. Now I want to display the contents from the DB along with the data that the user just entered.

Onsubmit of the 1 jsp I am inserting the data into the DB and forwarding it the same jsp (1st jsp). So that the user can enter data again. And I am refreshing the 2nd jsp every 4 sec so that I can get the data just entered. Both the jsps are displayed in the same page.

Thank you in advance
 
Ranch Hand
Posts: 2908
1
Spring Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you tried passing the data to the second JSP page and displaying it using EL or struts bean tag.
 
Mahesh Lohi
Ranch Hand
Posts: 151
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks the reply. I have no idea what struts bean are. Please let me know how to use them.

Thank you in advance.
 
Sagar Rohankar
Ranch Hand
Posts: 2908
1
Spring Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Mahi Lohi wrote:. I have no idea what struts bean are.


Struts bean:
They are simple, classic bean like bean. You can use by extending ActionForm class.

Struts bean "tag":
A JSP tag for getting the scoped bean values. Look here:
http://struts.apache.org/1.3.10/struts-taglib/dev_bean.html
 
get schwifty. tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic