The gotoRoute() method doesn't support hashes, but you can accomplish this
by using the url action helper to construct the url based on your route, and
then concatenate your hash to it. Then call the redirector's gotoUrl method:

$url = $this->_helper->url->url(array('module' => 'blog',
'controller' => 'documentation', 'action' => 'tags'));
$url .= "#add";
$this->_helper->redirector->gotoUrl($url);

--
Hector


On Wed, Dec 9, 2009 at 1:51 PM, Jason Austin <jason_aus...@ncsu.edu> wrote:

> I am trying to use the redirector action helper to call gotoRoute.
> The page I need to go to is something like
> http://mywebsite.com/blog/documentation/tags/#add which would take me
> to the "add" anchor in the tags page.  To go to that URL, my code is:
>
> $this->_helper->redirector->gotoRoute(array('module' => 'blog',
> 'controller' => 'documentation', 'action' => 'tags'));
>
> That takes me to http://mywebsite.com/blog/documentation/tags/ but I
> need to add "#add" to the end of that.  Any idea how one would
> accomplish that?
>
> Thanks
> Jason
>
> --
> Jason Austin
> Senior Solutions Implementation Engineer
> NCSU - OIT - Outreach Technology
> jason_aus...@ncsu.edu
>

Reply via email to