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

Dynamic key=>value segments in Zend Router

Need to achieve dynamic router param segmenting in Zend Router. The idea is: have the url: /route/:route/resource/:resource/:identifier, with the following configuration: 'orchestration.rest.dynamic-router' => array( 'type' =>…
0
votes
1 answer

What is the purpose of the fourth argument in a Zend Framework Route instantiation?

Here is an example of a Route, taken from this page: $route = new Zend_Controller_Router_Route_Regex( 'blog/archive/(\d+)-(.+)\.html', array( 'controller' => 'blog', 'action' => 'view' ), array( 1 =>…
Chris Laplante
  • 29,338
  • 17
  • 103
  • 134
0
votes
1 answer

Zend Router Logic

I am struggling with how to handle my URL mapping. Right now, I am working on putting together a photo gallery system using the Zend Framework. The gallery system can handle categories and galleries. A category can have child categories or galleries…
Drew Fulton
  • 203
  • 2
  • 13
0
votes
1 answer

Making restful requests in zend framework 3

So I am trying to make restful web request but, I may have configured it wrong which I cannot seem to fix. I have mind that. /companies GET -> index method /companies POST -> add post method /companies/1 GET -> show…
0
votes
1 answer

Change default REST response to be only XML in Zend

I've worked on this code base and it responds with html when i access a site www.site.com/version/ However, If i access www.site.com/version?format=xml, it displays output in xml. How can I change the Zend code to ONLY output in XML irrespective of…
siliconpi
  • 8,105
  • 18
  • 69
  • 107
0
votes
1 answer

Mutiple ids on Rest Router / Zend?

I think I have the same issue as this guy - http://framework.zend.com/issues/browse/ZF-9385?page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel "If I call something like this /mod/con/123/abc on a RESTful Controller I would…
siliconpi
  • 8,105
  • 18
  • 69
  • 107
0
votes
2 answers

How to extract special characters from route in Zend framework 3

I'm sending a url that has special characters in them. /contacts?advanceSearch=true&advanceSearchType=rating&advanceSearchValue=A1A+ As you see the variable value of advanceSearchValue is A1A+ But when I retrieve this in…
Ali Rasheed
  • 2,765
  • 2
  • 18
  • 31
0
votes
1 answer

How to set default module with zend route?

I've three module default frontend backend I'd like to hide default and frontend module from the url So I'd like to set the module depending on the controller because the defautl module is only used for errorController Thank you
ÉricP
  • 843
  • 4
  • 12
  • 17
0
votes
1 answer

Zend Route: if link starts with /something then ignore other rules

I have two modules that should over ride other urls, basically /management/category/edit/id/1 (Edit Category Page) /management/category/index (Index Page Of Category in Management Module) /management/category (Index Page Of Category in Management…
azz0r
  • 3,283
  • 7
  • 42
  • 85
0
votes
1 answer

Zend Framework - cms page routing

I have a CMS where the admin builds its own recursive page structure. Every page has its own "url-key". Next the url-key is used in combination with the page structure to build the URL structure so you get the following structure: {rootpage…
sroes
  • 14,663
  • 1
  • 53
  • 72
0
votes
2 answers

Route path for different api version in zend framework 3

This is how I defined route for my api. It is prefixed with /api/v1. But now few new modules are added in api v2 and all v1 apis are remains same and available in v2. How can i modify this routes that will serve all routes belongs to /api/v1 and…
nithinTa
  • 1,632
  • 2
  • 16
  • 32
0
votes
1 answer

regular Expression alphnummeric with some spaces

to avoid downvoting, I tried everything in this post: regular expression to allow spaces between words I use RexEx in combination with ZF3 routing. at the moment my expression looks like follows: 'id' => '[a-zA-Z0-9 ]*', it accepts alphanumeric…
pia-sophie
  • 505
  • 4
  • 21
0
votes
1 answer

datatype in request parameter $id = $this->params()->fromRoute('id');

so far I have worked only with integer values as request parameters in urls. Now I need to work with strings which contain spaces etc. for example: "xyz 666 888-VCT" I send the route and parameters out of my view script:
pia-sophie
  • 505
  • 4
  • 21
0
votes
1 answer

Zend route with unlimited parameters

I am using Zend 1.10. I am trying to create a route for unlimited variables like abc.com/var1/var2/var3 and so on. Till now i have searched and find out that i can add route for each variable like $route = new Zend_Controller_Router_Route( …
Davinder Kumar
  • 652
  • 4
  • 17
0
votes
3 answers

ZF3: How to route to specific controller/action based on method and route?

In my module's module.config.php, I have something like this: namespace Application; return [ //... // myroute1 will route to IndexController fooAction if the route is matching '/index/foo' but regardless of request method 'myroute1' =>…
evilReiko
  • 19,501
  • 24
  • 86
  • 102