syntax highlighting: take 2.

This commit is contained in:
Taylor Otwell 2011-08-02 22:54:10 -05:00
parent e25c119fad
commit 833b6ba881
1 changed files with 6 additions and 0 deletions

View File

@ -16,18 +16,24 @@ ### Beautifully Expressive Syntax
Redirect to a named route and flash something to the session: Redirect to a named route and flash something to the session:
```php ```php
<?php
return Redirect::to_profile()->with('message', 'Welcome Back!'); return Redirect::to_profile()->with('message', 'Welcome Back!');
``` ```
Retrieve a blog post and eagerly load the comments using Eloquent ORM: Retrieve a blog post and eagerly load the comments using Eloquent ORM:
```php ```php
<?php
$posts = Post::with('comments')->find(1); $posts = Post::with('comments')->find(1);
``` ```
Get input from the previous request to re-populate a form: Get input from the previous request to re-populate a form:
```php ```php
<?php
echo Input::old('email'); echo Input::old('email');
``` ```