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

  • Home
  • SEARCH
  • 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

I'm working on a Zend Framework (v1.7) application that calls for a few forms
All, I am working on a Zend Framework based web application. We keep encountering
I am working on a huge php application with Zend framework, in that project
I am working on implementing Zend Framework within an existing project that has a
The Zend Framework based site I have been working on is now being migrated
I'm working on creating a domain layer in Zend Framework that is separate from
I'm struggling to build a simple zend framework application that can call jQuery. So,
I have a Zend Framework application based on the quick-start setup. I've gotten the
Background, I'm running a Zend Framework application. Trying to squeeze the most performance out
I am working with Zend framework and just hate the fact that I seem

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.