Heres the controller:
class HomeController extends BaseController {
public function index() {
return View::make('home', array('username' => 'Vaughan'));
}
}
Here the home blade view:
{{ $username }}
Yet the view is outputting exactly this:
{{ $username }}
The variable is not being rendered. Could this be something to do with Apache or PHP?
You need to name your view with blade extension:
home.blade.php
That's all.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With