Last active
August 29, 2015 13:57
-
-
Save JBreit/9821620 to your computer and use it in GitHub Desktop.
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
<?php | |
class BaseController extends Controller { | |
/** | |
* Setup the layout used by the controller. | |
* | |
* @return void | |
*/ | |
protected function setupLayout() | |
{ | |
if ( ! is_null($this->layout)) | |
{ | |
$this->layout = View::make($this->layout); | |
} | |
} | |
} |
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
<h1>Authors Home Page</h1> | |
<?php echo $name; ?><br /> | |
<?php echo $age; ?><br /> | |
<?php echo $location; ?><br /> | |
<?php echo $specialty; ?><br /> |
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
<?php | |
/* | |
|-------------------------------------------------------------------------- | |
| Application Routes | |
|-------------------------------------------------------------------------- | |
| | |
| Here is where you can register all of the routes for an application. | |
| It's a breeze. Simply tell Laravel the URIs it should respond to | |
| and give it the Closure to execute when that URI is requested. | |
| | |
*/ | |
Route::get('/', function() | |
{ | |
return View::make('hello'); | |
}); | |
Route::get('authors', array('uses'=>'authors@index')); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment