
I got the something relevant for HTML on w3schools.com. But could not find anything for visualforce.
http://www.w3schools.com/tags/tryit.asp?filename=tryhtml_redirect
Will be grateful if I get assistance for this.
Thanks.
3 answers
Hi Satish,
For redirecting to "ThankYou" page after clicking on Save button you have to make your save method to return a pageReference dataType. Then in that method you have to return like this :
return new pageReference('/ThankYou');
Then at "ThankYou" page for redirecting to "Home" page after 5 seconds you have to do javascript code something like this :<script>
window.onload = window.setTimeout(redirect(),5000);
function redirect(){
window.location.href='/Home';
}
</script>