Allan,
you can specify the redirect url for succes by setting the variable "url" in your POST. (For example in a hidden input field for your form)
In this case you need to turn on the redirect to the users intended page.
The users intended page is then sent within the variables the ZD sends to your portal.
If you then ignore the variable and set it staticly in the form, then, if authenticated, the user is redirected to the page you've set there.
Upon failure, the user is sent back to your portal.
You can catch the variables by using javascript getvariable or a simpel GET in html/PHP and add them to the end of the portal url.