Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Auto-Submiiting a Form Question

Posted on 2006-06-14
3
Medium Priority
?
284 Views
Last Modified: 2012-06-27
Hi All,
I have a page where I want it to auto-submit without the user seeing it. What is the easiest way to do this? The reason I need to do this is because the php curl function won't operate properly if I re-post the page to itself and then pass on to a Paypal page. I now have two pages set-up but as the second page is purely functional (no use to the user) I don't want them to have to click another submit button. Is there an easy php or javascript solution to this? Any help would be much appreciated.
Thanks,
D
0
Comment
Question by:dereksheahan
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 43

Accepted Solution

by:
TimCottee earned 2000 total points
ID: 16901716
Hi dereksheahan,

<body onload="document.forms[0].submit();">

So when the page loads, the form is submitted automatically.

Tim Cottee
0
 
LVL 20

Expert Comment

by:Gawai
ID: 16902121
to work timcottee code, u should write <form> attributes as well.

<body onload="document.Autofrm.submit();">
<form action="finalpage.htm" method="post" name="Autofrm">
<input type......................>
.....

</form>
</body>



@-GaWai-@
0
 
LVL 43

Expert Comment

by:TimCottee
ID: 16902173
gawai,

Indeed, though that was assumed (perhaps I shouldn't have).

Tim
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Australian government abolished Visa 457 earlier this April and this article describes how this decision might affect Australian IT scene and IT experts.
Dramatic changes are revolutionizing how we build and use technology. Every company is automating, digitizing, and modernizing operations. We need a better, more connected way to work together as teams so we can harness the insights from our system…
This tutorial walks through the best practices in adding a local business to Google Maps including how to properly search for duplicates, marker placement, and inputing business details. Login to your Google Account, then search for "Google Mapmaker…
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…
Suggested Courses

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question