Imitate the REST api using url parameter based implementation

Reason for this implementation is some clients having trouble configuring the rest api either due to not having proper access to the webserver in a shared hosting environment or security restrictions. But still from icehrm frontend we need to consume the backend rest api.
This commit is contained in:
Alan Cell
2020-11-06 20:00:53 +01:00
parent da55c7a2d2
commit 2abe52963f
7 changed files with 236 additions and 3 deletions

View File

@@ -1,3 +1,7 @@
<?php
include ('config.php');
include (APP_BASE_PATH.'rest.php');
if (isset($_REQUEST['method']) && isset($_REQUEST['url'])) {
include (APP_BASE_PATH.'api.php');
} else {
include (APP_BASE_PATH.'rest.php');
}