> This is to inform that solved the problem of executing two action (of
two
> forms) at the same time.
>
> YES, it does work. I had to forms one doing update in a database via a
URL
> that executes a servlet, and the other was doing upload of files. They
both
> work great, however aftter hours I noticed that I first got to do the
update
> in the database and then (last action) do the upload. For some reason
I
> don't know the other way around does not get the 2 actions done. The
way the
> code is now it does.
I read about some other guy trying to do this and it surprised me that
it should work. So I made a test for myself. At first everything seemed
fine. Two forms were posted to their (in this case the same) action. BUT
then I tried three forms only 2 got to their destination. My guess is
that the 2 working was more of an "accident"; the first just happened to
have enough time to perform its action before the other one was posted,
but when I had 3 there was only time for one to get posted before the
last one.
Therefore I would NOT rely on this to work in deployment. Especially if
you are creating an internet application (as opposed to intranet) where
people might use modems, it might not even work for two.
But then again these are again only my guesses. Maybe someone here knows
better.
I think there is a (HTML-)way around this, though it's a little ugly and
I haven't tried it. You could try using different targets for you forms
(<form target="...">) and make the result end up in different
frames/windows. So, post one of them to the main frame and the other to
some dummy/hidden/popup window (that for example is closed when the
first one is finished).
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets