• 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
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

popup window changed to internal iframe. problem using window.opener

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


in my application there are lots of searches that need to performed inside various pages, the search windows will in opened in the popup. once the search was done the popups will set the values into the parent window components using window.opener.componentName = somevalue.
now instead of opening the popups i have developed a modal window kind of component which will display inside the main parent window (darkening the parent window and highlight the custom modal window). I have successfully overridden the window.open method to get the popup url to open the page inside the custom modal window. the custom made modal window has an iframe which will load the requested search page.
now the problem is.... there was no code change done by the developers in their pages to call the new functionality, as i have overridden the window.open, it takes care of all the things. the problem is the popup uses window.opener to set the values to the parent window. is there any other way to set the values to the main frame from the popup iframe so that developers need not change all their page codes from window.opener to window.parent etc etc...
the reason for this is, if the client rejects the new feature there is no need to rollback the old codes(although we use sourcesafe)

thanks

Vijay Veeraraghavan
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well the iframe whould be using parent and window.opener.

I think you really are going to confuse developers in the future when they have to take this system over.

Eric
 
I like you because you always keep good, crunchy cereal in your pantry. This tiny ad agrees:
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth
https://coderanch.com/t/751654/free-earth-friendly-heat-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic