JavaScript Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsProgrammingJavaScript Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old May 11th, 2004, 06:31 PM
nedrich nedrich is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2004
Posts: 2 nedrich User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Refresh parent window from modal child window

Hello all,

The title says it all. The modal child window doesn't recognize the parent as its parent. I've tried various ways to pass in a handle to the parent window using dialogArguments but have been unsuccessful. Any ideas?

Keep in mind I know how to refresh a parent window from a normal child window (window.opener.location.reload()). Doing it from a MODAL child window is a different problem.

Little Neddy Knickers

Reply With Quote
  #2  
Old May 12th, 2004, 03:22 PM
msbhaskar msbhaskar is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2004
Posts: 1 msbhaskar User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Arrow Refresh parent window from modal child window

You can pass the arguments to the modal window as follows

window.showModalDialog('test.htm',window);

if you need to access this in the child window then you can declare a variable

var xWin=window.dialogArguments;

basically your normal javascript parent will be the variable xWin.

You can use
xWin.location.replace(xWin.location);

to refresh the parent window.
but remember to close the child window before doing that. If you use modeless dialog,
the child window will automaticlly be closed.

Hope this helps.

Reply With Quote
  #3  
Old May 18th, 2009, 02:17 AM
barbieavril barbieavril is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2009
Posts: 1 barbieavril User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 m 52 sec
Reputation Power: 0
Talking

Quote:
Originally Posted by msbhaskar
You can pass the arguments to the modal window as follows

window.showModalDialog('test.htm',window);

if you need to access this in the child window then you can declare a variable

var xWin=window.dialogArguments;

basically your normal javascript parent will be the variable xWin.

You can use
xWin.location.replace(xWin.location);

to refresh the parent window.
but remember to close the child window before doing that. If you use modeless dialog,
the child window will automaticlly be closed.

Hope this helps.



This really helps. Thank you so much...

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingJavaScript Development > Refresh parent window from modal child window


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.

© 2003-2014 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap