You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: controllers.md
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -17,7 +17,7 @@
17
17
18
18
Controllers are classes that are responsible for accepting user input and managing interactions between models, libraries, and views. Typically, they will ask a model for data, and then return a view that presents that data to the user.
19
19
20
-
The usage of controllers is the most common method of implementing application logic in modern web-development. However, Laravel also empowers developers to implement their application logic within routing declarations. This is explored in detail in the [routing document](/docs/routing). New users are encouraged to start with controllers. There is nothing that route-based application logic can do that controllers can't.
20
+
The usage of controllers is the most common method of implementing application logic in modern web-development. However, Laravel also empowers developers to implement their application logic within routing declarations. This is explored in detail in the [routing document](/docs/routing). New users are encourage to start with controllers. There is nothing that route-based application logic can do that controllers can't.
21
21
22
22
Controller classes should be stored in **application/controllers** and should extend the Base\_Controller class. A Home\_Controller class is included with Laravel.
23
23
@@ -40,7 +40,7 @@ Controller classes should be stored in **application/controllers** and should ex
40
40
<aname="controller-routing"></a>
41
41
## Controller Routing
42
42
43
-
It is important to be aware that all routes in Laravel must be explicitly defined, including routes to controllers.
43
+
It is important to be aware that all routes in Laravel must be explicitly defined, including routes to controllers.
44
44
45
45
This means that controller methods that have not been exposed through route registration **cannot** be accessed. It's possible to automatically expose all methods within a controller using controller route registration. Controller route registrations are typically defined in **application/routes.php**.
46
46
@@ -78,7 +78,7 @@ Great! Now we can access our "admin" bundle's home controller from the web!
78
78
<aname="action-filters"></a>
79
79
## Action Filters
80
80
81
-
Action filters are methods that can be run before or after a controller action. With Laravel you don't only have control over which filters are assigned to which actions. But, you can also choose which http verbs (post, get, put, and delete) will activate a filter.
81
+
Action filters are methods that can be run before or after a controller action. With Laravel you don't only have control over which filters are assigned to which actions. But, you can also choose which http verbs (post, get, put, and delete) will activate a filter.
82
82
83
83
You can assign "before" and "after" filters to controller actions within the controller's constructor.
Copy file name to clipboardExpand all lines: views/home.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -230,7 +230,7 @@ You can access your message from the view with the Session get method:
230
230
<aname="errors"></a>
231
231
## Errors
232
232
233
-
To generating proper error responses simply specify the response code that you wish to return. The corresponding view stored in **views/error** will automatically be returned.
233
+
To generate proper error responses simply specify the response code that you wish to return. The corresponding view stored in **views/error** will automatically be returned.
0 commit comments