|
 |
asptoday_discuss thread: Re: Refresh window from popup window
Message #1 by Mike Lau <mike_lau_hk@y...> on Thu, 31 Jan 2002 17:38:44 -0800 (PST)
|
|
you can use something like below:
var frm = window.opener.document.forms[0];
frm.textbox1.value = "somevalue";
window.close();
mike
--- Tan Chye Ting <chyeting18@h...> wrote:
> does anyone know how to refresh a window from a pop
> up window. i'm trying
> to update my table with the data i input in the
> popup window so that i can
> see the changes in the table..please help...i now
> there is something i can
> do to close the window using javascript like
> onclick="javascript:window.close();"..i just wonder
> whether there is a way
> i can do to refresh the main window once i click on
> a button..i really
> need help on this one..thanx
__________________________________________________
Do You Yahoo!?
Great stuff seeking new owners in Yahoo! Auctions!
http://auctions.yahoo.com
Message #2 by "Tan Chye Ting" <chyeting18@h...> on Fri, 1 Feb 2002 09:04:31
|
|
that wasn't what i wanna do ...what i wanna do is refresh a page from
another popup window not the same page
> Do onething. onclick of the refresh link/button, submit the form
> to itself. (i.e) action page is nothing but y'r current page.
>
> You can do it in the folllowing way:
>
> If it is the link -
> <a
>
href="javascript:document.formname.action='currentpage.asp';document.formna
m
> e.submit()">
> Refresh</a>
>
> If it is a button -
> <input type="button" value="refresh"
>
onclick="document.formname.action='currentpage.asp';document.formname.submi
t
> ()">
>
>
>
> -----Original Message-----
> From: Tan Chye Ting [mailto:chyeting18@h...]
> Sent: Thursday, January 31, 2002 5:46 PM
> To: ASPToday Discuss
> Subject: [asptoday_discuss] Refresh window from popup window
>
>
> does anyone know how to refresh a window from a pop up window. i'm
trying
> to update my table with the data i input in the popup window so that i
can
> see the changes in the table..please help...i now there is something i
can
> do to close the window using javascript like
> onclick="javascript:window.close();"..i just wonder whether there is a
way
> i can do to refresh the main window once i click on a button..i really
> need help on this one..thanx
Message #3 by "Tan Chye Ting" <chyeting18@h...> on Fri, 1 Feb 2002 09:16:44
|
|
that is not what i mean..i want to refresh another window from the popup
window once i have updated my database with the data i input into the
popup window..the flow goes like this
1)i click on a button in the main window
2)a popup window appears
3)i input data into the popup window
4)update the database by calling Add.asp
5)close the popup window from Add.asp
6)refresh the main window so i can see the changes in the database
my problem is in step 6, because i can't refresh the main window,so i
can't actually see the changes i have made through the pop up window...i
will want to invoke an event to refresh the main window once i have
updated the database
> Do onething. onclick of the refresh link/button, submit the form
> to itself. (i.e) action page is nothing but y'r current page.
>
> You can do it in the folllowing way:
>
> If it is the link -
> <a
>
href="javascript:document.formname.action='currentpage.asp';document.formna
m
> e.submit()">
> Refresh</a>
>
> If it is a button -
> <input type="button" value="refresh"
>
onclick="document.formname.action='currentpage.asp';document.formname.submi
t
> ()">
>
>
>
> -----Original Message-----
> From: Tan Chye Ting [mailto:chyeting18@h...]
> Sent: Thursday, January 31, 2002 5:46 PM
> To: ASPToday Discuss
> Subject: [asptoday_discuss] Refresh window from popup window
>
>
> does anyone know how to refresh a window from a pop up window. i'm
trying
> to update my table with the data i input in the popup window so that i
can
> see the changes in the table..please help...i now there is something i
can
> do to close the window using javascript like
> onclick="javascript:window.close();"..i just wonder whether there is a
way
> i can do to refresh the main window once i click on a button..i really
> need help on this one..thanx
|
|
 |