PHP code example of rasuvaeff / yii3-maintenance-mode
1. Go to this page and download the library: Download rasuvaeff/yii3-maintenance-mode 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/ */
rasuvaeff / yii3-maintenance-mode example snippets
use Psr\Http\Message\ResponseFactoryInterface;
use Rasuvaeff\Yii3MaintenanceMode\ConfigMaintenanceProvider;
use Rasuvaeff\Yii3MaintenanceMode\MaintenanceMiddleware;
$middleware = new MaintenanceMiddleware(
provider: new ConfigMaintenanceProvider($config),
responseFactory: $container->get(ResponseFactoryInterface::class),
);