• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

Sending data via java class

 
Ranch Hand
Posts: 151
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
He loves you so much! And I'm baking the cake! I'm going to put this tiny ad in the cake:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic