1

I'm using Kohana 2 on my admin panel. But when click Add New button, get Page Not Found warning.

Its warning:

The requested page was not found. It may have moved, been deleted, or archived.

panel/system/core/Kohana.php [842]:

The page you requested, admin/corporate/addnew, could not be found.

Thats 842. line:

throw new Kohana_404_Exception($page, $template);

That warning page image:

enter image description here

Karmacoma
  • 658
  • 1
  • 13
  • 37
  • Can you show us your `corporate` controller? You have an `addnew` method in there, right? Or are you redirecting this route to another location? – Sampson May 17 '12 at 13:42

1 Answers1

0

Unless you have a route setup to handle this particular URL, the default route will NOT handle this. The url "admin/corporate/addnew" is trying to use the admin controller, the corporate action, and an id called 'addnew'. Im not sure how you have your application structured, but perhaps you need to write a route in your bootstrap.php that looks something like this:

Route::set('admin_corporate', 'admin/corporate(/<action>(/<id>))')
    ->defaults(array(
        'controller' => 'corporate',
        'action'     => 'index'
    ));

This would need to go BEFORE your default route.

pogeybait
  • 3,065
  • 2
  • 21
  • 23