home.php 995 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. class Home_Controller extends Base_Controller {
  3. /*
  4. |--------------------------------------------------------------------------
  5. | The Default Controller
  6. |--------------------------------------------------------------------------
  7. |
  8. | Instead of using RESTful routes and anonymous functions, you might wish
  9. | to use controllers to organize your application API. You'll love them.
  10. |
  11. | This controller responds to URIs beginning with "home", and it also
  12. | serves as the default controller for the application, meaning it
  13. | handles requests to the root of the application.
  14. |
  15. | You can respond to GET requests to "/home/profile" like so:
  16. |
  17. | public function action_profile()
  18. | {
  19. | return "This is your profile!";
  20. | }
  21. |
  22. | Any extra segments are passed to the method as parameters:
  23. |
  24. | public function action_profile($id)
  25. | {
  26. | return "This is the profile for user {$id}.";
  27. | }
  28. |
  29. */
  30. public function action_index()
  31. {
  32. return View::make('home.index');
  33. }
  34. }