Reputation: 21
I have a poll system provided by an outsourced application.
After users choose one of the radio button's choices and click a Submit button, my JavaScripts will redirect them to a specific url (ex. http://www.poll.com/answer). This is a must for posting data to that outsourced application, so this url must be processed.
But what if I don't want to show users this page, but redirect them to a finish page, What should I do with this condition in JavaScripts?
It looks like this.
..When click Submit..
Upvotes: 0
Views: 139
Reputation: 3198
I'm going to make a few assumptions to clarify my understanding.
You have two options:
Server Side
As far as the user is concerned, he never leaves your site.
Client Side - Ajax
Let me know if you need further clarification.
Upvotes: 1
Reputation: 1579
One possible solution, depending on if you are doing server side programming, is to submit the data in the code behind.
After submitting the data to your code that handles the form submission. Your code passes the values to the third party instead of having the third party be the form submission location. Since you are handling the form submission with your code, you are free to redirect the user as you please.
If you aren't doing server side programming, I'm not sure if there is a way to hide the form submission location from the user.
Upvotes: 1