How can I force Zend Router to assemble proper urls when the site is running under a directory?
Here's what I mean:
$this->view->url(array('controller' => 'controller', 'action' => 'action'), null, true)
Would usually return something like /controller/action where in my case it returns /tbogdanov/brandenburg/controller/action, because the site is running in the directory /tbogdanov/brandenburg.
That is actually a good URL and I have no problem with it. However, when passed to $this->_redirect() the redirector just prepends the directory again. So, the final redirect url now looks like this: /tbogdanov/brandenburg/tbogdanov/brandenburg/controller/action.
Now, that's incorrect.
Is there any setting I might be missing? It seems zend is aware it is running in a directory/sub-directory, but still at some point, it ignores it. I am looking for a good generalized solution, no str_replace ones!
Also the method should work properly even if at some point the project is moved in the root directory (which will happen).