Created
May 17, 2017 17:39
-
-
Save silentworks/e5267401f0ce2a2040a881a882917761 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 | |
$app = new Slim\App(); | |
$app->group(new ApiRoutes); | |
// ApiRoutes | |
class ApiRoutes | |
{ | |
public function __construct($app) | |
{ | |
$app->get('/', [$this, 'home']); | |
} | |
public function home($request, $response) | |
{ | |
return $response->write('Hello World'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment