PHP code example of genericmilk / rollout
1. Go to this page and download the library: Download genericmilk/rollout 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/ */
genericmilk / rollout example snippets
if(Rollout::from('2019-12-12 00:00:00')->until('2019-12-13 20:00:00')->go()){
return 'Rolling out is pretty fun';
}
if(Rollout::from('2019-12-12 00:00:00')->until('2019-12-13 20:00:00')->go()){
return 'Rolling out is pretty fun';
}else{
return 'Pity you cannot see it until you meet the threshold ;)';
}
$Status = Rollout::from('2019-12-12 00:00:00')->until('2019-12-13 20:00:00')->status();
return 'The rollout is currently at '.$Status.'%';