Multiple Window Challenge

Closing a Popup once Form is Submitted

Page 1 of 1

1 Replies - 3206 Views - Last Post: 09 December 2004 - 06:44 AM Rate Topic: -----

#1 philiprakusen  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 21
  • Joined: 09-December 04

Multiple Window Challenge

Posted 09 December 2004 - 06:26 AM

I have a popup window listing some products that a user can add to an order. Each product has a quantity textbox, and there is a master submit button at the foot of the page.

When the form is submitted, ColdFusion puts all of the products that have a quantity value into an order.

This works fine, but I’m having trouble automatically closing the popup window once the form has been submitted and displaying the order in the main window.

Any ideas how this can be done?

In summary, I think the events should happen in the following order:

1. User clicks submit in the popup window
2. Javascript verification
3. Form submitted
4. ColdFusion processes
5. Popup window closes
6. Main window shows order

Is This A Good Question/Topic? 0
  • +

Replies To: Multiple Window Challenge

#2 Amadeus  Icon User is offline

  • g+ + -o drink whiskey.cpp
  • member icon

Reputation: 248
  • View blog
  • Posts: 13,507
  • Joined: 12-July 02

Re: Multiple Window Challenge

Posted 09 December 2004 - 06:44 AM

Im assuming you're using javascript to open the popup in the first place. If so, you can write a javascript function that, once the submit button has been pressed, closes the popup (self.close) and refreshes the parent (window.opener.location.href = <insertparenturlhere>). Some poeple like to use the relaod() method, but it can cause problems in different browsers.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1