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
5
votes
1 answer

How to route multi subdomain with zend router hostname

I need to create routing in Zend to simply copy the current live site url structure which is sadly inconsistent What i want to do is to route subdomain as follow: www.site.com -> static router a.site.com & b.site.com -> category…
Komang
  • 5,004
  • 4
  • 29
  • 33
5
votes
1 answer

Zend framework not able to route the translated child routes

I am new to Zend framework 3 and was trying to translate the routes and i have partially succeeded.I am able to translate the main route and redirect it to the required location but for child routes the translation works but the redirection doesn't.…
4
votes
1 answer

zend rest controller routing to specific controller

I am fairly new to zend framework. I have been trying to write RESTful controller using Zend_Rest_Controller. I built one from a good tutorial http://www.techchorus.net/create-restful-applications-using-zend-framework It works perfectly. So I went…
4
votes
2 answers

Invalid Controller Specified Error, even though the controller is present

I have a camelcased controller name called MenuItem. And Also I have created a router for this particular controller as $routeMenuItem = new Zend_Controller_Router_Route('/menu-item/:action/:menu/:parent/:id/*', array( 'controller' =>…
mrN
  • 3,734
  • 15
  • 58
  • 82
4
votes
1 answer

Zend Routes and HTTP Verb/Method

Hi I am trying to setup some REST routes in a Zend app, I am wondering how I can restrict the HTTP method on which the route can be accessed. $route = new Zend_Controller_Router_Route('user/reset_password', array( 'module' =>…
Paul Carey
  • 516
  • 1
  • 4
  • 15
4
votes
1 answer

How to retain default Zend route

I am trying to setup meaningful URLs such as http://www.site.com/company/department however it hammers my existing URLs which are in the Controller/Action shape. In my bootstrap, I create my new route as follows: $frontController =…
DatsunBing
  • 8,684
  • 17
  • 87
  • 172
4
votes
2 answers

Convert Zend_Rest_Route code to handle 2 params?

I have Zend code from http://www.chrisdanielson.com/2009/09/02/creating-a-php-rest-api-using-the-zend-framework/ which looks like this: $this->bootstrap('Request'); $front = $this->getResource('FrontController'); $restRoute = new…
siliconpi
  • 8,105
  • 18
  • 69
  • 107
4
votes
4 answers

URL rewriting for Magento module

I have created a New Module in Magento and named it as "article". It has two Front end controllers index and article. And in the article controller i have an action called "archives" to list the articles on the front end / website based on the…
4
votes
2 answers

404 The requested URL could not be matched by routing

I'd just started to learn zend-framework and following this user guide. I'm able to successfully install the zend skeleton application and moved on to the routing and controllers. But after completion of the tutorial I requested the url:…
Mohammad Faisal
  • 5,783
  • 15
  • 70
  • 117
4
votes
3 answers

ZF2 route parameters with slash

Is it possible to assemble a route with parameters containing forward slashes? Config: 'someroute' => array( 'type' => 'Zend\Mvc\Router\Http\Segment', 'options' => array( 'route' => 'someroute/:path', …
machete
  • 1,127
  • 2
  • 13
  • 26
4
votes
3 answers

Zend Route Url with regex

I'm trying to create a route that will "cover" this kind of URLs: www.test.com/parent1/parent2/parent3/item www.test.com/parent1/parent2/parent3/parent4/item1 Number of those parents in unspecified, and it should only serve to give a better, more…
alokiN
  • 41
  • 1
  • 2
4
votes
5 answers

Zend Framework 2 segment route required segment

I am trying to make a route (or two) that will let me invoke two different actions with the below URL formats. mydomain.com/profile mydomain.com/profile/1234/something For the second format, the 1234 should be a required integer value, while…
ba0708
  • 10,180
  • 13
  • 67
  • 99
4
votes
3 answers

Fetching Zend Framework URL parameters

I'm building my first Zend Framework application and I want to find out the best way to fetch user parameters from the URL. I have some controllers which have index, add, edit and delete action methods. The index action can take a page parameter and…
Freek Vanraes
  • 227
  • 5
  • 11
3
votes
2 answers

Zend_Controller_Router_Route_Regex Optional Parameters with Reverse

I've successfully created my Route using Regex. I have Several Optional Parameters in my route that I don't want displayed in the URL Helper unless the user has specified them. How can I accomplish this? This is what I currently have …
user1287238
  • 31
  • 1
  • 3
3
votes
1 answer

Routing for country , province , city , product in Zend Framework

This url structure is proposed for SEO optimization. So suggesting another structure will not work. Structure proposed is example.com///// example.com/en/spain I wish to point to CountryController…
Hari K T
  • 4,174
  • 3
  • 32
  • 51
1
2
3
21 22