ZF-3925: Ability to override self URL on Zend_OpenId


At the moment this fetches from the $_SERVER supervariable directly. It would be nice to have a $selfUrl static in the style of the $exitOnRedirect that allows the return url to be defined cleanly if it's different than expected.


Patch for zend_openid class with the above suggestion implement.

Why do you need it? Doesn't the second argument of Zend_Consumer::login($id, $returnTo) work for you?

Because it assumes that the URL in the server variable is the URL that user is trying to auth against. It's a subtle condition, but it's we had it when the auth was being done on a different address than that user was viewing (the auth code was centrally located, but being used as a service by a number of different domains, for a shared sign on type solution).