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:
  • Devaka Cooray
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • Paul Clapham
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Saloon Keepers:
  • Tim Holloway
Bartenders:

post data on popup then refresh parent window

 
Ranch Hand
Posts: 188
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Hi,

I want to pop a window from my main page using the following JS


From this window i want to pos an array of data to a servlet. in my servlet i will set that array to the session. the variable is located on the main page. AFTER the post from the popup i want to refresh the main page so that variable will show everything in that array on the main page.

how can i do this to make sure the refresh is done after the post from the popup is complete?

TIA john
 
Ranch Hand
Posts: 2458
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Already answered: https://coderanch.com/t/439562/HTML-JavaScript/post-data-from-one-window

In the popup window, you can access the parent window which opened the popup window using the window.opener property in JS.

 
John Schretz
Ranch Hand
Posts: 188
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Can you elaborate a bit more on that then? Its not the exact same question because i have change what i wanted to do a bit.
 
Sheriff
Posts: 67759
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
The issue is the same -- use the opener reference to access the opening page. Please continue any further discussion in the original topic.
 
I like tacos! And this tiny ad:
Paul Wheaton's 16th Kickstarter: Gardening playing cards for gardeners and homesteaders
https://coderanch.com/t/889615/Paul-Wheaton-Kickstarter-Gardening-playing
    Bookmark Topic Watch Topic
  • New Topic