1. Go to this page and download the library: Download phore/micro-app library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
phore / micro-app example snippets
$app = new App();
$app->router
->onGet("/", // Define a Action for HTTP-GET-Requests to /
function() {
return "Hello world"; // Important: Return true if output was already sent.
}
);
$app->serve(); // Run the App