Submit Form on Page Load

K

Keith

Is it possible to submit a form as soon as the page it is on loads and then
redirect to another page?

Thanks
 
R

Ray at

With client-side code, you can call the .submit method of your form, but do
you mind if I ask what the point of doing this is?

Ray at work
 
K

Keith

I have a pagee which performs an insert to a SQL DB, but I also need to
perform another diifferent insert at the same time, so I thought if I submit
my first form, redirect to my second page and then automatically submit my
second form and redirect that would solve the problem.
 
D

David C. Holley

That can all be done without having to submit a form when the page
loads. You have two options...

1) Execute both inserts from the same page by combining the code from
both - and making any neccessary accomodations since the form no longer
exists.

2) Execute the first page and then redirect to the second. Using this
option you should be able to handle any unexpected problems.

David
www.gatewayorlando.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,156
Messages
2,570,878
Members
47,408
Latest member
AlenaRay88

Latest Threads

Top