File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes HTML, CSS and JavaScript and the fly likes two actions with single button Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "two actions with single button" Watch "two actions with single button" New topic

two actions with single button

Archana Annamaneni
Ranch Hand

Joined: Jan 29, 2003
Posts: 147
I have this problem

I have a popup window with a close button , when user clicks on that close button i want to do two actions , clsoe that window and call a jsp page .This close button is in the html form . I think i need javascript , but i am not sure how to do that .

Is there any other way to do that.
Somebody please provide me with some sample code
Eric Pascarello

Joined: Nov 08, 2001
Posts: 15385
basic idea before i leave work..
an example
if you do it this way you might run into the problem of the form not submitting....then again I am not sure what you need to be done. call it the 5pm brain freeze
Randall Twede
Ranch Hand

Joined: Oct 21, 2000
Posts: 4351

not an answer, but something to be aware of. if your popup window has a close button in the top right corner, "X", the user is very likely to use it instead of the close button in your form.

Visit my download page
I agree. Here's the link:
subject: two actions with single button
It's not a secret anymore!