commit 9a1dc6cef413fa4dab516edf016ae74ebe08865c parent 05856f266edfe20ae2a3357185abc8de40da1728 Author: MTRNord <mtrnord1@gmail.com> Date: Mon, 2 Feb 2015 20:07:27 +0100 not complete working :/ Diffstat:
| M | core/api/v1/api.php | | | 3 | ++- |
| M | docs/nginx.htaccess | | | 6 | ++---- |
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/core/api/v1/api.php b/core/api/v1/api.php @@ -34,7 +34,8 @@ class MyAPI extends API return "Only accepts GET requests"; } } - // Requests from the same server don't have a HTTP_ORIGIN header + // Requests from the same server don't have a HTTP_ORIGIN header + if (!array_key_exists('HTTP_ORIGIN', $_SERVER)) { $_SERVER['HTTP_ORIGIN'] = $_SERVER['SERVER_NAME']; } diff --git a/docs/nginx.htaccess b/docs/nginx.htaccess @@ -1,11 +1,10 @@ location /oauth2callback { -rewrite ^(.*)$ [PFAD_TO_PROJECT]/core/backend/admin/modules/modul_g-plus-login/handle.php redirect; +rewrite ^(.*)$ /[PFAD_TO_PROJECT]/core/backend/admin/modules/modul_g-plus-login/handle.php redirect; } location / { if (!-e $request_filename){ rewrite /^([^\.]+)$ /$request_uri.php; } if (!-e $request_filename){ -rewrite api/v1/(.*)$ [PFAD_TO_PROJECT]/core/api/v1/api.php?request=$1 break; +rewrite api/v1/(.*)$ /[PFAD_TO_PROJECT]/core/api/v1/api.php?request=$1 break; } -} -\ No newline at end of file