开发者

Kohana Framework: 'HTTP_Exception_404 [ 404 ]: The requested URL welcome/index was not found on this server.'

开发者 https://www.devze.com 2023-03-11 09:11 出处:网络
I followed this tutorial with only one difference. Instead of naming it hello.php, I named it welcome.php. The sources of my files are identical to that of the tutorials, and they are in the correct p

I followed this tutorial with only one difference. Instead of naming it hello.php, I named it welcome.php. The sources of my files are identical to that of the tutorials, and they are in the correct paths. What could cause this?

I am ref开发者_StackOverflowerencing it with 'kohana/index.php/welcome' as per the tutorial.


You have to change your controller's name to Welcome instead of Hello

Class Controller_Welcome extends Controller {
   public function action_index()
  {
      echo 'hello, world!';
  }
}  

I guess you forgot to change the controller name?


I named it welcome.php. The sources of my files are identical to that of the tutorials

if that is so, you need to rename your controller Controller_Welcome instead of Controller_Hello

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号