Created
January 5, 2015 15:31
-
-
Save bkozora/f5612ba9d8080f6b53b1 to your computer and use it in GitHub Desktop.
Laravel - Define Layout on a Controller
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class UserController extends BaseController { | |
/** | |
* The layout that should be used for responses. | |
*/ | |
protected $layout = 'layouts.master'; | |
/** | |
* Show the user profile. | |
*/ | |
public function showProfile() | |
{ | |
$this->layout->content = View::make('user.profile'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment