Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • 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
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
  • Knute Snortum
Sheriffs:
  • Liutauras Vilda
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Joe Ess
  • salvin francis
  • fred rosenberger

Losing Form on Spawning Itself

 
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here's an issue that I'm sure people have already asked on this board...

I am running STRUTS. In my JSP code, I launch a link to the SAME JSP as a popup. In other words, the same form bean is used in the spawned page. The problem is that after the spawned window is closed, the information in the PARENT form is LOST. Any suggestions???

The parent launches the popup directly from the JSP via JScript or HTML.
 
Ranch Hand
Posts: 153
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Whatz the scope of the bean?

cheers
skini
 
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check if this form is being stored in the session, according to the action tag's "scope" attribute.

Second, make sure the parent window's form is submitted, or else the data you see in its form is in the client-side, not in the server-side!

If you don't submit (or can't submit) the parent window's form, you'll have to fill the popup form with JavaScript.
 
pchen
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the reply. I'm sorry I have not gotten back to you quickly. Anyway, I am working on your suggestion. However, I am having trouble switching out the form bean with the original form bean saved in the session. Any suggestions?
 
Legend has it that if you rub the right tiny ad, a genie comes out.
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!