Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4245012
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T03:47:02+00:00 2026-05-21T03:47:02+00:00

i am working on a zend framework application, and to my surprise, the default

  • 0

i am working on a zend framework application, and to my surprise, the default routing is not working as expected. This is my url:

http://localhost/zend_app/public/index/test

and it is supposed to route to the index controller > test action in default module. But it is not working as expected.

When i printed the request params, i got the action as “get” and id as “test“.

array (
  'controller' => 'index',
  'action' => 'get',
  'id' => 'test',
  'module' => 'default'
)

FYI, I configured certain regex routes in my bootstrap file like this:

protected function _initRestRoute()
    {
        require_once 'Zend/Controller/Front.php';    
        require_once 'Zend/Controller/Router/Route.php';

        $ctrl  = Zend_Controller_Front::getInstance();
        $router = $ctrl->getRouter();

$router->addRoute(
            'route2',
            new Zend_Controller_Router_Route_Regex(
                                            'api/([^-]*)/([^-]*)\.([^-]*)', 
                                            array(
                                            'action' => 'index'
                                            ),
                                            array(
                                                1 => 'module',
                                                2 => 'controller'
                                            )
        ));

}

But none of the routes match my url above.
I could not understand what could be the issue.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-21T03:47:03+00:00Added an answer on May 21, 2026 at 3:47 am

    Read carefully the notes under Zend Rest Route.

    Zend Rest Route is designed to simplify RESTful applications, and routes requests based on the URL and request method.

    In this case, you are issuing a GET request for item ‘test’ under the index controller.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

All, I am working on a Zend Framework based web application. We keep encountering
I have been working on a new installation of a Zend Framework application for
I'm working on multi-tenant application in Zend Framework which gets it's tenantID from the
This article explains how to use Zend in Codeigniter. http://www.beyondcoding.com/2008/02/21/using-zend-framework-with-codeigniter/ I am using XAMPP
I'm working on an application developed using Zend Framework. I have defined relationships in
I am working on a Zend Framework application with PHP. I have a form
Im working on a what I thought would be simple application using zend framework.
I'm working on a Zend Framework (v1.7) application that calls for a few forms
I have been trying to get JQuery Sortable working on my Zend Framework application
I'm working on a small php application using Zend Framework. I created a form

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.