Javascript reload page after popup submit Coldfusion - javascript

I have a popup window where my user can edit information displayed on the parent page. When someone press submit changes on the popup window i need the popup to close and also the parent page to reload to display the new information.
I know there are a lot of examples out there but the questions displayed here did not provide me with enough information to complete my task.
I am currently using onClick="history.go(0)" which take me back to the parent page but does not reload the page

The question was a bit vague (not really a question at all, even), but you can try window.location.href="/parentpage";

To close the pop up window from within the pop up window use this:
self.close();
To RELOAD the window that opened the pop up use this in the pop up window:
window.opener.href = 'URL';
This should be pretty close to what you need.

Related

Jquery mobile popup refresh page after the second one

I have a question, i generate a page with a javascript code and i use popup. This page works great but :
- When i open a popup for the first time, i can close it and it's works normally
- When u open a popup for the second time, i can close it but the page is refresh after this one was closed.
I don't understand why it's happen only after the second closed. I really want to be unable to close how often i want my popup. If someone have an idea to solve this problem please tell me.
Thanks you for all your contribution to my probleme.
nb : i have already try to set the history option to false of jquery mobile popup.

how we can restrict user to click or go on the browser window until they close the opened pop up window?

I am making a web application which takes the exam related programming languages, and i am opening a pop up window for test when a user click to start a test ,
but i want to restrict them to go on the main broweser window until they submit the exam(pope up window closed automatically) or they will close manualy
As far as i know its not possible with javascript. but cant you better use a box that will lay on top of the original page content like you can do with Jquery.
http://jqueryui.com/dialog/#modal-form
Removing the buttons and other forms of cancelation and only leave a post button when all answers are given.

Having difficulty closing a PopUP window, after update and submit button

So, I have a javaScript that calls an ASP page, using ShowModalDialog ... it works great, passes the correct information, the user is then prompted with radio button to answer a question, then if the user presses "submit" ... the data is written to a SQL table. this all works; however, I cannot get the window to close. The behavior is the program opens another page (same content as in the window popUP) only it is full page size.
When I tried to add the following code: Response.Write("script language='javascript'?window.close();") ... I get the same behavior with a message indicating that the program is trying to close the window.
this is so frustrating because I don't understand why closing a window is so diffcult.
Please help if you can.

How to make my screen wait till my child window get closed, in firefox

Issue: Should restrict the webpage from submission and moving to the next, till the child window gets closed.
Technology: jsp
Browser: firefox.
Code used for Opening:
retValue = window.open(child_url,',',"Height=400px,Width=670px,status:no,top=190px,left=200px");
Desc:
Clicked on one link in the page and opened up the child window from the firefox browser using the window.open command. But just after the click of the link, along with the opening up of the child window, the main page is also getting submitted and moved to the next page.
The same logic in ie works fine. In ie am using showModalDialog() which works without any issue.
NB: Hoping for an alternative way, which is something other than giving if conditions to the page submission line.
Could someone pls help... thanks in advance
I would recommend that you move up to the jQuery modal dialog. It's browser-independent, and your user will understand that he is interacting with a modal dialog that must be closed before proceeding. With a separate window or tab (your current solution), it's too easy for the user to get lost and click away from the browser altogether.

How to close parent window on child window open using window.open()

Using javascript "window.close()" method after opening new window using "window.open", it serve the problem i.e. but it will ask a confirmation message to user whether he really wants to close the window or not... if user selects yes then the parent window will close and if not then he will remain on the same window and new window will not get open up..
So is there any way so that parent window will get closed without asking any confirmation message and new window will gets open up ?
No. It´s a security feature. You are trying to manipulate an application on another users machine.
If you put it in another context it becomes clear why it is as it is and why it should be that way: Would you like if your email client suddenly closed cause you read an email?
EDIT: What you can do is having the login window trigger a navigate event in it´s opener so the first page gets replaced by the billing info page. Then it can close itself.

Categories

Resources