PHP code example of rollerworks / pdb-symfony-bridge
1. Go to this page and download the library: Download rollerworks/pdb-symfony-bridge 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/ */
rollerworks / pdb-symfony-bridge example snippets
use Rollerworks\Component\PdbSfBridge\HttpUpdatedPdpManager;
use Symfony\Component\Cache\Psr16Cache(;
// Any PSR16 Compatible adapter can be used, but it's recommended to use
// A caching adapter that allows easy invalidation (like Pdo or Memcache).
$cacheAdapter = ...;
$cache = new Psr16Cache($cacheAdapter);
// Optional, if not provided created as shown
// $httpClient = new \Symfony\Component\HttpClient\HttpClient::create();
$manager = HttpUpdatedPdpManager::create($cache, /*$httpClient*/);
// Not
use Rollerworks\Component\PdbSfBridge\StaticPdpManager;
// Any PSR16 Compatible adapter can be used, but it's recommended to use
// A caching adapter that allows easy invalidation (like Pdo or Memcache).
$cacheAdapter = ...;
$cache = new Psr16Cache($cacheAdapter);
// Provide the lists as described, realpath (not contents are string)
$publicSuffixList = ...; // File provided from https://publicsuffix.org/list/public_suffix_list.dat
$topLevelDomainList ...; // File provided from https://data.iana.org/TLD/tlds-alpha-by-domain.txt
$manager = new StaticPdpManager($publicSuffixList, $topLevelDomainList, $cache);
// Not
bash
$ php composer.phar
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.