Thank you for your reply. The best example i can say is ..same as the sitepoint login page. when we enter the required information its taking us to the appropriate page(the page we came from).Is this possible with the client side javascripting?
It doesn't require javascript, and is pretty much guaranteed to work.
To keep people informed about what is going to happen, you should also have link telling people where they're going to be redirected off to.
Bookmarks