473,396 Members | 1,827 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Main > Popup > Popup > Close popup AND new URL in main?

Hi
From my main window I open a series of popup (one close - next opens)
in a mockup for a registration proces.

From the last popup, I want to click a buttom, so the popup closes and
the URL in the original main window changes and the window get focus.

Uses
<script language="JavaScript"><!--
name = 'mainwindow';
//--></script>

to target the main window - but I havn't succeeded in closing the
popup.

Any suggestions?
Jul 23 '05 #1
7 1880
Jens Peter Hansen wrote:
Hi
From my main window I open a series of popup (one close - next opens)
in a mockup for a registration proces.

From the last popup, I want to click a buttom, so the popup closes and
the URL in the original main window changes and the window get focus.

Uses
<script language="JavaScript"><!--
name = 'mainwindow';
//--></script>

to target the main window - but I havn't succeeded in closing the
popup.


self.close();

in the popup window.

--
andy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/
Jul 23 '05 #2
Randy Webb <hi************@aol.com> wrote in message news:<Md********************@comcast.com>...
From the last popup, I want to click a buttom, so the popup closes and
the URL in the original main window changes and the window get focus.
but I havn't succeeded in closing the
popup.


self.close();

in the popup window.


Yes - with self.close() I can close the popup - but I can't figure out
how to change the content in the main window at the same time.

Please have a look at a small example I have placed at
http://www.purhusnet.dk/popupsequence/ - in this example I do change
content in main window, but the popup retains focus.

regards jph
Jul 23 '05 #3
Jens Peter Hansen wrote:
Randy Webb <hi************@aol.com> wrote in message news:<Md********************@comcast.com>...
From the last popup, I want to click a buttom, so the popup closes and
the URL in the original main window changes and the window get focus.
but I havn't succeeded in closing the
popup.


self.close();

in the popup window.

Yes - with self.close() I can close the popup - but I can't figure out
how to change the content in the main window at the same time.

Please have a look at a small example I have placed at
http://www.purhusnet.dk/popupsequence/ - in this example I do change
content in main window, but the popup retains focus.

regards jph


<A HREF="./red.html" TARGET="hovedvindue"
oncklick="setTimeout(closeIt,1000)">- red content</A>

function closeIt(){
self.close();
}

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/
Jul 23 '05 #4

Thanks Randy - that works as can be seen on
http:/www.purhusnet.dk/popupsequence (har to correct a typing error in
oncklick)

regards jph
*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 23 '05 #5
Jens Peter Hansen wrote:
Thanks Randy - that works as can be seen on
http:/www.purhusnet.dk/popupsequence (har to correct a typing error in
oncklick)


When I go through it now, in Mozilla, I get two windows at the end,
instead of one......
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/
Jul 23 '05 #6

Correct - lucky me, I'm only producing a mockup so for a start it is OK
that it's only working in IE. Smarter people than me must solve the
Mozilla/Netscape issue later :-)

regards jph
*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 23 '05 #7
Jens Peter Hansen wrote:
Correct - lucky me, I'm only producing a mockup so for a start it is OK
that it's only working in IE. Smarter people than me must solve the
Mozilla/Netscape issue later :-)


The reason it works in IE and not Mozilla is because IE lets you name an
already open window on the fly, Mozilla doesn't.

Also, you may want to read
<URL: http://www.jibbering.com/faq/#FAQ4_24 >

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/
Jul 23 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Madhav | last post by:
I have the following statements in my script. ---------------------------------------------------------- textToWrite = "<HTML> \n" + "<HEAD> \n" + "<TITLE>Calendar</TITLE> \n" + "<SCRIPT...
5
by: Hemanth | last post by:
Hello there, I'm running a script that opens a popup window (which is basically a form with checkboxes and a submit button). When I click the submit button I want to run a PHP script and target...
2
by: julie.siebel | last post by:
I KNOW this can't be as hard as I am making it. I have a travel client with two related websites. On the homepage of the new site (Call it "Site A") I am building for them, there is a link to a...
4
by: stevong | last post by:
It works on Konquerer though. I remember it works on IE too. I've tried window.close() too. Doesn't work on Firefox also. I've also tried to create a function. It doesnt work on Firefox also....
2
by: Richard Maher | last post by:
Hi, I'm trying to use the Visibility Style attribute for a Div to effectively PopUp a lightweight window with some additional context-sensitive information, when a user mouses over a given...
3
by: Jimmy | last post by:
It is also possible for popup window to call function in main window by using the opener property. Will "opener.someFunctionInMain(param1, param2)" in the popup window work? It's possible for...
2
by: thuythu | last post by:
Please help me.... I used and Javascript to view the data. But when i click button open a popup windows, then select data and click save button. The popup close and return the main page, but the...
5
by: Thelma Roslyn Lubkin | last post by:
I am still having trouble trying to use a popup form to allow user to set filters for the main form. The main form is based on a single table. The popup contains 5 listboxes, so the user can...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.