Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
syncEnrollments
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Yeray Santana Hualde
syncEnrollments
Commits
8068a88b
Commit
8068a88b
authored
Aug 03, 2011
by
Michael Hasselbring
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
removed routes directory
parent
12185bd4
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
117 deletions
+0
-117
filters.php
application/routes/filters.php
+0
-70
routes.php
application/routes/routes.php
+0
-47
No files found.
application/routes/filters.php
deleted
100644 → 0
View file @
12185bd4
<?php
return
array
(
/*
|--------------------------------------------------------------------------
| Filters
|--------------------------------------------------------------------------
|
| Filters provide a convenient method for attaching functionality to your
| routes. Filters can run either before or after a route is exectued.
|
| The built-in "before" and "after" filters are called before and after
| every request to your application; however, you may create other filters
| that can be attached to individual routes.
|
| Filters also make common tasks such as authentication and CSRF protection
| a breeze. If a filter that runs before a route returns a response, that
| response will override the route action.
|
| Let's walk through an example...
|
| First, define a filter:
|
| 'simple_filter' => function()
| {
| return 'Filtered!';
| }
|
| Next, attach the filter to a route:
|
| 'GET /' => array('before' => 'simple_filter', 'do' => function()
| {
| return 'Hello World!';
| })
|
| Now every requests to http://example.com will return "Filtered!", since
| the filter is overriding the route action by returning a value.
|
| To make your life easier, we have built authentication and CSRF filters
| that are ready to attach to your routes. Enjoy.
|
| For more information, check out: http://laravel.com/docs/start/routes#filters
|
*/
'before'
=>
function
()
{
// Do stuff before every request is executed.
},
'after'
=>
function
(
$response
)
{
// Do stuff after every request is executed.
},
'auth'
=>
function
()
{
return
(
!
Auth
::
check
())
?
Redirect
::
to_login
()
:
null
;
},
'csrf'
=>
function
()
{
return
(
Input
::
get
(
'csrf_token'
)
!==
Form
::
raw_token
())
?
Response
::
error
(
'500'
)
:
null
;
},
);
\ No newline at end of file
application/routes/routes.php
deleted
100644 → 0
View file @
12185bd4
<?php
return
array
(
/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is the public API of your application. To add functionality to your
| application, you just add to the array located in this file.
|
| Simply tell Laravel the HTTP verbs and request URIs it should respond to.
| You may respond to the GET, POST, PUT, or DELETE verbs. Enjoy the simplicity
| and elegance of RESTful routing.
|
| Here is how to respond to a simple GET request to http://example.com/hello:
|
| 'GET /hello' => function()
| {
| return 'Hello World!';
| }
|
| You can even respond to more than one URI:
|
| 'GET /hello, GET /world' => function()
| {
| return 'Hello World!';
| }
|
| Allow URI wildcards using the (:num) or (:any) place-holders:
|
| 'GET /hello/(:any)' => function($name)
| {
| return "Welcome, $name.";
| }
|
| Ready to learn more? Check out: http://laravel.com/docs/start/routes
|
*/
'GET /'
=>
function
()
{
return
View
::
make
(
'home/index'
);
},
);
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment