Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

tt313

macrumors newbie
Original poster
Dec 7, 2011
1
0
I have a web page with 6 sliding panels.
The last panel has an email form.
Everything functions fine except for one item:

Once a user hits the Submit button on the form in the last panel the panels slide back to the first (0-default) panel.

How would I go about maintaining focus on that last panel (the one with the form on it) once the submit button is hit so that I can display the confirmation text?

Thanks in advance for any help or tips.
 
Without knowing more details about your setup; Add (or use an existing) form field to note when the page has been submitted. You could use a cookie to note when the page has been submitted, or add a query string on the URL, or maybe use any server side languages to add something to the page.

Then on page load, you can use that knowledge to jump to the correct panel on page load. You would make use of the onload event for the page.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.