API相關全部小寫化

This commit is contained in:
Yuan Chiu 2014-11-13 17:43:46 +08:00
parent f38a92554c
commit 0d42a96787
4 changed files with 5 additions and 5 deletions

View File

@ -9,4 +9,4 @@ RewriteEngine On
## For API ## For API
RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (API|api)/v2/(.*)$ API/v2/index.php/$1 [L] RewriteRule (API|api)/v2/(.*)$ api/v2/index.php/$1 [L]

View File

@ -71,7 +71,7 @@ $app->error(function (\Exception $e) use ($app) {
// 測試用 Say hello!~~~ // 測試用 Say hello!~~~
$app->get('/Hello/:name', function ($name) use ($app) { $app->get('/hello/:name', function ($name) use ($app) {
$app->view(new \JsonApiView()); $app->view(new \JsonApiView());
$app->add(new \JsonApiMiddleware()); $app->add(new \JsonApiMiddleware());
@ -83,7 +83,7 @@ $app->get('/Hello/:name', function ($name) use ($app) {
// ============================================================================ // ============================================================================
$app->group('/Users', 'APIrequest', function () use ($app) { $app->group('/users', 'APIrequest', function () use ($app) {
// 建立帳號 // 建立帳號
$app->post('/', function () use ($app) { $app->post('/', function () use ($app) {
@ -114,13 +114,13 @@ $app->group('/Users', 'APIrequest', function () use ($app) {
}); });
$app->post('/:user_id/Login/', function ($user_id) use ($app) { $app->post('/:user_id/login/', function ($user_id) use ($app) {
// TODO: 登入 // TODO: 登入
APIdisableFunc($app); APIdisableFunc($app);
}); });
}); });
$app->group('/UTokens', 'APIrequest', function () use ($app) { $app->group('/tokens', 'APIrequest', function () use ($app) {
$app->get('/:token', function ($token) { $app->get('/:token', function ($token) {
//echo "Login Token: $token"; //echo "Login Token: $token";