ajax test
This commit is contained in:
13
endpoints/global/page.php
Normal file
13
endpoints/global/page.php
Normal file
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
|
||||
require_once "lib/page.php";
|
||||
require_once "lib/navigation.php";
|
||||
|
||||
function endpoint($endpoint_data): array
|
||||
{
|
||||
return match ($endpoint_data["action"]) {
|
||||
"getNavigation" => getNavigationEndpoint(),
|
||||
"getPage" => getPageEndpoint($endpoint_data["page"], $endpoint_data["site"]),
|
||||
default => ["Status" => "Fail", "message" => "Invalid action"],
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user