PHP code example of phputil / flags-pdo

1. Go to this page and download the library: Download phputil/flags-pdo 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/ */

    

phputil / flags-pdo example snippets




use phputil\flags\pdo\PDOBasedStorage;

$pdo = /* create you PDO instance here, e.g.: new PDO( 'sqlite:example.sqlite' ) */;
$storage = new PDOBasedStorage( $pdo );

// Now use it with phputil\flags
$flags = new phputil\flags\FlagManager( $storage );
...