Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Referencing another web page from a "child" page? 1

Status
Not open for further replies.

SalemGrafix

IS-IT--Management
Jun 12, 2003
46
0
0
US
I am creating a website for a friend, and I'm not sure if this is something that can be done with HTML, Javascript, or at all:

Main Page displays info from a database. If the user viewing the page clicks on "Add" to add more information, a "child" page pops up, and asks for data.

"Child" page has the form, asks for the data, and once the user hits submit, the data is then stored in the database.

So far, so good, I have this complete. Here's where it gets tricky:

I want the "Child" page to auto-close once the data has been saved in the database (not a big deal there), but also refresh the page on the Main page (this is where I'm stuck).

I'm not sure if one web page can refresh (or redirect) another web page. Is this possible? And if so, anyone have any code or examples to demonstrate this? I have searched Google, but I think I'm missing the proper keyword or terminology for finding this, if it's even possible.

Thanks for any help you can provide.
 
You'd need to use JavaScript for this. From the popup, try:

Code:
window.opener.location.reload(true);

If you get any problems with this, you should ask in forum216.

Hope this helps,
Dan



Coedit Limited - Delivering standards compliant, accessible web solutions

Dan's Page [blue]@[/blue] Code Couch:
Code Couch Tech Snippets & Info:
 
Dan,

Thank you very much for the quick response, this works perfectly, and is exactly what I was looking for.

Thank you so much.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top