Questions tagged [zend-route]

Routing in Zend Framework's MVC implementation. Zend Framework is an open source, object-oriented web application framework implemented in PHP 5 and licensed under the New BSD License.

zend-route is a tag suitable for any questions regarding routing in Zend Framework's MVC implementation, url handling, or any other matter affecting or affected by routing in Zend Framework.

319 questions
0
votes
1 answer

What schould be the output of Zend\Mvc\Router\RouteInterface::assemble() in ZF2

I'm writing my custom router for a Zend Framework 2 project extending Zend\Mvc\Router\RouteInterface. The routes should come from a database (large project with hundreds of pages). A working Router obviously only needs two methods: match() and…
mdthh
  • 1,248
  • 1
  • 13
  • 22
0
votes
1 answer

Error url parameter when save form element in zend framework 2

In module.config.php ... 'may_terminate' => true, 'child_routes' => array( 'resetpassword' => array( 'type' => 'Literal', 'options' => array( 'route' => '/reset-password', 'defaults' => array( …
Hai Truong IT
  • 4,126
  • 13
  • 55
  • 102
0
votes
1 answer

Zend Router Route Regex with Search params

Trying to grab the params after ?. I need them to add to the Zend_Paginator. ex: http://www.example.com/test/show?name=xxx&age=20&sex=m Building a paginator for search results. Is there any solution for that ? $router = new…
0
votes
1 answer

Implementing the Url Rewriting for a Zend Application

I am doing my first Zend Application and I am finally done with the coding side. But the problem which I have is Client has asked to rewrite the Url's which follows the SEO and as I don't have much knowledge of the Zend Router,I am finding myself…
Nishant Shrivastava
  • 2,113
  • 3
  • 26
  • 43
0
votes
1 answer

How to get params in contollerFactory zend 2?

I have simple factory and I would like to get params from route here:
0
votes
1 answer

Zend index action parameters

I want to have url example.com/invoice/id/5 Create action function indexAction(){ echo "test"; } Now i try access this action from url example.com/invoice/ or example.com/invoice/index And also pass parameters example.com/invoice/id/5 Here I'm…
Wizard
  • 10,985
  • 38
  • 91
  • 165
0
votes
1 answer

Change url from Action zf2

I am implementing a search an sending a search form to an action. Everything is working as expected but the url after the submit isn't very friendly and contain undesirable information. It is showing the whole request query array as a query string.…
Frank
  • 49
  • 7
0
votes
1 answer

I want to build a custom router for Zend framework supports lang & country

Here is an example of what i want to do The Url will be as follow http://www.example.com/en/us/directory/companies/view/4433225.html Where is en: is the lang us: is the country directory: is the module companies: is the controller view: is the…
Mohammad Alqersh
0
votes
1 answer

ZF2 - Two routes with overlapping patterns

my question regards Zend Framework 2. I have two routes that overlap a bit - one is in the form of: /announcements/index[/:type][/:status] and the other: /announcements[/:action][/:id] They are defined in configuration in the same order as…
vatzec
  • 403
  • 1
  • 4
  • 7
0
votes
1 answer

Unable to get parameters using Zend Routing Chain

In my bootstrap file, I have the following routing chain. The desired behaviour is to send any request through /usa/:controller/:action to the local module. For instance, when http://{hostname}/usa/index/index is called, the request goes through…
Nolan Knill
  • 499
  • 5
  • 19
0
votes
2 answers

zend regex route with negative lookahead

I'm trying to write a regex route in zend (1.11) that matches urls ending in /foo but not if they start with /bar e.g. /foo - match /any/words/foo - match /any/words - no match (doesn't end in /foo) /any/words/barfoo - no match (doesn't end in…
xanld
  • 977
  • 1
  • 11
  • 22
0
votes
3 answers

zf2 routing is not working

My root url is http://restaurent.local i want to route like this http://restaurent.local/menuedit/test/1. But this not working This is my code 'menuedit' => array( 'type' => 'Zend\Mvc\Router\Http\Literal', 'options' =>…
deepu sankar
  • 4,335
  • 3
  • 26
  • 37
0
votes
1 answer

Adding parameters to URL in ZF2

I am trying to construct url which looks like this: abc.com/folder?user_id=1&category=v Followed the suggestion given in this link: How can you add query parameters in the ZF2 url view helper Initially, it throws up this error Query route…
notnotundefined
  • 3,493
  • 3
  • 30
  • 39
0
votes
1 answer

Zend routing issue with dynamic segment

I'm working on a Zend project and I have some issues with the router/routes. I want the have these URLs: www.mydomain.tld/contact/person www.mydomain.tld/contact/person/formsend www.mydomain.tld/contact/person/id The third segment in the URL will…
Timo002
  • 3,138
  • 4
  • 40
  • 65
0
votes
1 answer

How to remove routing error in zf2?

I used authentication in zend module but when i render it gives me error like Zend\View\Renderer\PhpRenderer::render: Unable to render template "calendar/index/login"; resolver could not resolve to a files here is my module.config.php:
Muhammad Arif
  • 1,014
  • 3
  • 22
  • 56