aspose file tools*
The moose likes Struts and the fly likes Sending data via java class Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Sending data via java class " Watch "Sending data via java class " New topic
Author

Sending data via java class

Mahesh Lohi
Ranch Hand

Joined: Jun 22, 2009
Posts: 150
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
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

Have you tried passing the data to the second JSP page and displaying it using EL or struts bean tag.


[LEARNING bLOG] | [Freelance Web Designer] | [and "Rohan" is part of my surname]
Mahesh Lohi
Ranch Hand

Joined: Jun 22, 2009
Posts: 150
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

Joined: Feb 19, 2008
Posts: 2902
    
    1

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
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Sending data via java class
 
Similar Threads
making my bean accesible to 3rd JSP using request scope
retreiving request parameter of second frame in first
regarding jsp validation
Passing Data From A Servlet to Javascript excuting at onload
Printing a set of JSPs