Reputation: 16863
In ZF1 you were able to create a SEF urkl by doing the following
<a href="<?php $this->url(array('controller'=>'MyCOntroller',
'action'=>'MyActions'));?>">My link</a>
how do we do that in ZF2?
Upvotes: 0
Views: 490
Reputation: 25431
You achieve similar results also in Zend Framework 2 with something like following:
<a href="<?php echo $this->url(
'route-name',
array('controller'=>'MyCOntroller', 'action'=>'MyActions')
); ?>">My link</a>
Check the reference about routing and the docs about the URL view helper and the Controller URL Plugin Helper
Upvotes: 1